Reference

Block Size

Block size is the smallest unit of space a filesystem allocates to a file. Because files are rounded up to whole blocks, a file smaller than one block still consumes a full block, which is why many tiny files use more disk space than their byte sizes suggest.

APIs & internalsGeneral

Block Size

Also known as: filesystem block size, cluster size, filesystem block size

Block size is the smallest unit of space a filesystem allocates to a file. Because files are rounded up to whole blocks, a file smaller than one block still consumes a full block, which is why many tiny files use more disk space than their byte sizes suggest.

  • Block size is the smallest chunk of space a filesystem allocates; common defaults are around 4 KB.
  • Files round up to whole blocks, so size on disk is usually larger than logical byte size.
  • Many tiny files waste space in partly filled blocks, known as slack space.

What block size means

A filesystem does not store files byte by byte. It divides the volume into fixed-size blocks (also called clusters or allocation units) and hands out whole blocks at a time. A common default block size is 4 KB, though some filesystems and large volumes use larger blocks. Every file occupies a whole number of blocks, so its on-disk size is always rounded up to the next block boundary.

This rounding is the difference between a file's logical size (its actual byte count) and its size on disk (the blocks it reserves). A 1 KB note saved on a volume with 4 KB blocks still reserves a full 4 KB block.

Why small files cost extra space

When you store thousands of tiny files such as caches, thumbnails, and config fragments, each one rounds up to at least one block. The leftover space in a partly used block is wasted, a phenomenon called slack space. Across many small files this adds up to noticeably more disk usage than the sum of their byte sizes.

This is one reason app caches and message attachment thumbnails can balloon storage usage. A cleaner like Cleanor targets the high-volume offenders, such as duplicate photos and large media, where reclaimed blocks translate into meaningful recovered space rather than fighting per-file rounding overhead.

Related terms

Keep reading the reference.

Act on it

Guides and tools for this topic.