1. Introduction

VFAT and FAT32 are the two old file systems developed by Microsoft. Although they are very similar, since FAT32 is the successor of VFAT, they have some differences.

In this tutorial, we’ll look at the history of FAT file systems in general. We’re also going to explore the features and constraints of both the FAT32 and VFAT file systems and then compare them.

2. FAT in General

The first version of FAT as a file system was developed in 1977. It was intended to be used by MS-DOS and early versions of Windows OS. FAT and its successors had received major adoption in the OS world at that time. Four versions of FAT were developed: FAT12, FAT16, FAT32, and FAT64 (sometimes called exFAT or “extended FAT). Later on, Microsoft developed the NTFS file system, which is the successor of FAT file systems.

Each version was intended to fix problems in the last version. Most notably, each version of FAT significantly increased the size of the cluster, where the cluster is simply a logical internal storage unit on the disk:

FAT12 FAT16 FAT32 FAT64
Maximum partition size 16 MB 2GB 32 GB 128 PB
Maximum file size < 16 MB 2GB 4 GB 16 EB
Maximum cluster size 4 KB 64 KB 32 KB 32 MB

That means that each FAT version increased the theoretical threshold of the file system size. There were more changes, of course, but we’ll focus our attention specifically on FAT32 and the VFAT file system. Let’s start with VFAT.

3. VFAT

VFAT is the extension of the FAT12 and FAT16. It addressed the major problem that both FAT12 and FAT16 had – the limit of filename size. FAT12 and FAT16 followed the 8.3 (or sometimes called SFN) DOS file naming convention. That naming convention implied that a file name can consist of at most 8 characters, and it also may have an optional file name extension, that must be at most 3 characters long.

Another challenge was that SFN filenames, along with extensions, can consist only of ASCII characters. There were many more neat details and constraints in SFN that VFAT was designed to solve.

So, in VFAT, another naming convention – LFN (or long-file-name) was introduced. In LFN, a file name can consist of 255 characters and spaces. It also could contain multiple periods, which is impossible in pure FAT12 and FAT16.

LFN also supported UTF-16 file name encoding. Last but not least, LFN and VFAT, in general, are designed to be backward-compatible with FAT12 and FAT32 file systems. It means that VFAT can work with disk partitioned with FAT16 seamlessly:

FAT12/FAT16 VFAT
File name SFN (8.3 convention) LFN
File encodings ASCII ASCII, UTF-16

But, apart from this, VFAT had the same limitations as FAT16. We’ll talk about managing clusters and partitions on the disk in a moment.

4. FAT32

Still, the major problem of FAT16 and VFAT was also the clusters and partition management as it’s growing. To explain, we need first to understand that the disk itself is divided into partitions, and partitions consist of clusters:

DiskStructure

This is, of course, a very high level. Here, we can see that the disk has 4 partitions, each of which may have its file system, like in the example above. The way the file system structures data on disk depends heavily on the file system; we’ll still be talking about FAT, so let’s go on.

Now, let’s say we have a partition inside the disk for 512 MB. This partition is initially divided into clusters, 8K each in FAT16. The problem is that the number of clusters is also fixed for the partition in FAT16 and VFAT. That means that if the partition size grows, then the size of clusters inevitably has to grow too. So if the partition now becomes 1 GB, the cluster size becomes 16 K.

So why is this a problem in the first place? The problem is that FAT16 and VFAT consider a cluster to be a single separate unit. And if we have to save a file with a size of 10 bytes, it would occupy the entire cluster no matter what. This file now occupies this cluster, and no other data can be written in this particular cluster. So, we ended up in a predicament where 99% of the cluster size was wasted. The problem gets even worse if the partition grows in size.

So, FAT32 comes into play. For a partition less than 8 GB in FAT32, the cluster size remains, by default, 4 KB. This, of course, does not fully solve the problem of potentially wasted space when a 1-byte file occupies the entire 4 KB partition. Still, FAT32 at least does not suffer from making the conditions worse on larger partitions. This is the major difference between FAT32 and FAT16/VFAT.

5. Max Disk Size

Another thing to mention here is that FAT16 and VFAT, in particular, had one problem. The max partition size manageable by the file system was 2 GB. This is because each cluster is identified by 16 bits in FAT16. In FAT32, there is no such constraint as it uses 28 bits out of 32 to address a cluster (the last 4 bits were reserved for potential future usage).

That’s why the partition size can theoretically be as large as 8 TB for FAT32. In practice, Windows limits the partition size to 32 GB for FAT32. That mostly happened because, at a time, Microsft wanted to promote NTFS over the FAT file system, but still. This is the second significant difference between FAT32 and VFAT/FAT16.

6. Conclusion

In this article, we explored the difference between VFAT/FAT16 and FAT32.

Comments are open for 30 days after publishing a post. For any issues past this date, use the Contact form on the site.