Work out tar archive size instantly with clear inputs, formula shown and shareable results.
tar writes a 512-byte header per file and pads every file's data up to a block boundary, then appends two zero blocks at the end. For many small files that overhead is substantial — 120,000 files cost at least 61 MB of headers alone — though compression removes most of the padding because it is all zeros.
tar size
uncompressed = data + files x header block + padding to block boundaries + 2 end blocks; compressed = uncompressed / ratio
Padding is zero bytes and headers are highly repetitive, so both compress almost to nothing. The real data compresses at its own ratio.
It affects the write size to tape or pipe, not correctness. Larger blocking factors improve tape throughput but add more padding at the end of the archive.