Nepedia
Back to Discover
Fluent Reader
💻

Filename extension

technology Maturity 11-13 Next article →

A filename extension is a small tag at the end of a computer file name. It usually starts with a full stop, which is also called a period. You might see examples like .txt for text or .mp3 for music. These tags tell you about the contents of a file or how it should be used.

They help people understand what they are looking at on a screen. While they are helpful for humans, they are not the only way computers know what a file is. Many files also have hidden data inside them called metadata that describes the file.

How these tags work depends on the system your computer uses. In some older systems, the extension is a separate part of the file's identity. For example, the FAT file system used in DOS treats the extension as its own thing. In DOS and 16-bit Windows, names were limited to eight characters. Then, you would add a period and an extension of up to three letters.

Other systems, like Unix or NTFS, treat the extension as just more characters in the name. In these systems, a dot is just another character that can be used anywhere. This allows for much longer and more flexible names.

History shows how these rules have changed over time. An early operating system called CTSS kept the name and the type separate. Later, systems like CP/M and DOS continued this practice of using a dot to separate them.

When Windows 95 arrived, it used a system called VFAT to allow much longer names. This moved away from the old 8.3 rule where names were very short. Even modern systems like Windows NT and ReFS still use suffixes. They do this to make sure they stay compatible with older versions of Windows.

Sometimes you might see a file with more than one extension. This often means one file is tucked inside another through a process called nesting. A common example is a file ending in .tar.gz. The .tar part tells you it is an archive of many files. The .gz part tells you the file has been made smaller using a tool called gzip.

You might also find different files sharing the same extension. For instance, .rpm can be used for both package managers and RealPlayer files. This can sometimes make it hard to know exactly what a file is just by looking at its name.

It is important to remember that extensions are not always perfect. A person can change an extension to hide what is actually inside a file. This can be a way to disguise a file that might cause harm to a computer.

Because of this, experts suggest not trusting an extension alone. Many modern computers use a different method to stay safe. They look for a "magic number," which is a special sequence of bytes at the start of a file. This helps the computer identify the true type of the file regardless of its name.

500 words

Where will your curiosity go next?

Keep exploring at your chosen reading level.

More to explore

🔬 Go deeper

More advanced topics to explore

🪜 Step back

Simpler topics to build understanding

What is Nepedia?

A free, ad-free encyclopedia for children. Every article is written at five reading levels, so the same page works for a five-year-old and a fifteen-year-old — use the level switcher above to see this one change. No account needed to read.