What's The Difference Between Size And Size On Disk In Windows Folder Properties


winlogo.jpgOne of the most confusing things Windows users may come across, is what to believe the actual folders or files sizes are on disk. You probably seen it when right clicking on a folder and selecting Properties, then viewing the Size and Size on disk numbers that are displayed.

As you can see two different size values are being calculated. In reality both values are correct.  But which value is the the actual size of the file or folder you need to know?

That would be the Size value. Here's why:

Size is the actual size of the file or the folder. So if you were to transfer the file or folder to another drive, CD, DVD or USB drive, this would be the actual size in bytes that is being copied.

Size on disk means the size that is being taken up on the disk (your hard drive). What does that mean?

We know that a disk is made up of Tracks and Sectors. In Windows that means the OS allocates space for files in "clusters" or "allocation units".

The size of a cluster can vary, but typical ranges are from 512 bytes to 32K or more. For example, on my C:\ drive, the allocation unit is 4096 bytes. This means that Windows will allocate 4096 bytes for any file or portion of a file that is from 1 to 4096 bytes in length.

If I have a file that is 17KB (kilo bytes), then the Size on disk would be 20.48 KB (or 20480 bytes). The calculation would be 4096 (1 allocation unit) x 5 = 20480 bytes. It takes 5 allocation units to hold a 17KB file.

Another example would be if I have a file that is 2000 bytes in size. The file size on disk would be 4096 bytes. The reason is, because even though the entire file can fit inside one allocation unit, it still takes up 4096 of space (one allocation unit) on disk (only one file can use an allocation unit and cannot be shared with other files).

So the size on disk is the space of all those sectors in which the file is saved. That means,usually, the size on disk is always greater than the actual size.

So the actual size of a file(s) or folder(s) should always be taken from the Size value when viewing the properties window.

Filed under Windows Tips by  #

Comments on What's The Difference Between Size And Size On Disk In Windows Folder Properties Leave a Comment

December 17, 2008

Pavan Kumar @ 2:10 pm #

Very good and informative post.. 🙂

June 1, 2009

James Smith @ 5:43 pm #

I read your post (which is helpeful), but I have a slightly more specific question that I thought you might be able to help me with.

If I have a file that's "Size" is 3,764,140 bytes, but the "Size on disk" is 3,764,224 bytes, I understand that there are 84 bytes of wasted space in the last cluster of the file. From my previous knowledge, I understand that there may still be old data written to that "wasted space," even though its not used by the new file.

I noticed that when transferring the file to a CD, it still has the same "Size" (which makes sense), but also the same "Size on disk," as it did when it was on my computer's hard drive.

My question is, when transferring a file to a CD, does the computer only transfer the actual "Size" of the file, and so the reason the CD's "Size on disk" for that file is the same as the computer's "Size on disk" for that file, is because they have similar cluster sizes? Or is it that, when transferring a file to a CD, are you also moving any of the wasted space on the last cluster of the file (that 84 bytes of old data)? If this is not the case, how does the computer recognize to only transfer up to a certain point within the last cluster, and not transfer any old data on that "wasted space?"

Someone I know, told me that they thought that the file owned the entire cluster size, and as such, any transfer to CD would include the "old data" in the "slack space," as well as the data in the current file. I'm not sure how accurate this is, or maybe it is? I apologize for not being totally brief. But any help would be appreciated. Thanks in advance.

August 18, 2010

andy @ 8:38 pm #

So what does it mean when the size on disk is LESS than the size???? A folder I just recovered from a corrupted drive has 41 GB as the size, but only 14 as the size on disk. 🙁

November 2, 2010

Sathish @ 12:38 am #

relay valuable information for folder size explanation given in detail, thanks:)

November 21, 2010

Joan Hasnen @ 11:50 pm #

How can I change the Size on Disk to a different size? I am having a problem with Dreamweaver CS3 crashing. One source said that it is caused by a file being exactly 8,192 bytes. I have files that show 16,384 bytes on the Size on Disk, which is exactly twice the 8,192 bytes. I changed the no. of bytes in the file size by adding more text, but it did not change the Size on disk. Do you have any fixes for this?

December 22, 2010

rajendra @ 4:26 am #

Hi i heard something strange of this difference from my collegue. That some information regarding file creation will be stored in this space like when it was created language etc. He says that we can even read that information if you open that file in c or c++.
is it true?

February 6, 2011

farhadfery @ 5:14 am #

pretty cool. thanks

April 5, 2011

Sun William @ 8:41 pm #

I have one question. the Size on disk should be equal or larger than the Size in terms of above explanation. But I found that the Siz is larger than the Size on disk. Why

June 10, 2011

Dattatray @ 12:08 am #

Wow….great explanation

Leave a Comment

Fields marked by an asterisk (*) are required.

Subscribe without commenting