Skip to content
IGCSE·Tuition
ICT · Lessons

Distinguish file type from its visible extension

A name can say one thing while the file inside is something else entirely.

On this page
  1. How do extensions map to types?
  2. Worked example
  3. The mistake to watch for
  4. Check yourself
  5. Where this leads next

A file’s type is what it really contains and how software reads it. Its extension is the short label at the end of the name, such as .csv or .docx.

They usually match, but the extension is only a label, and you must be able to tell when they do not. This appears whenever you save, export or hand in work in file organisation and evidence.

All files below are invented.

How do extensions map to types?

ExtensionUsual typeHolds
.txtPlain textCharacters only, no formatting
.csvComma-separated valuesRows of values split by commas, no formulas or styles
.xlsxSpreadsheetCells, formulas, formatting
.docxWord-processed documentText, styles, layout
.pdfPortable documentFixed layout for viewing
.png / .jpgImagePixels; PNG keeps sharp edges, JPG compresses

The exact set depends on the software in your course, so check your own centre’s list.

  1. Show extensions in your file manager so the label is visible.
  2. Read the last extension in the name. That is the one the system acts on.
  3. Judge the type by how it was made, not by the name. A file created by exporting to CSV is a CSV. A file merely renamed is not converted.

Worked example

Invented folder contents:

stock_list.csv, stock_list.xlsx, stock_list.csv.txt, poster.png

Step 1. stock_list.xlsx is a spreadsheet, with formulas possible.

Step 2. stock_list.csv is plain comma-separated values, so no formulas remain.

Step 3. stock_list.csv.txt has two extensions. The last is .txt, so it opens as plain text, not as a CSV.

Step 4. poster.png is an image. A word processor can place it, but cannot edit it as text.

Answer: three different types plus one mislabelled file. The fix for the third is to save again with the type chosen in the save dialog, leaving the base name stock_list.

The mistake to watch for

Aiman (invented) renames marks.xlsx to marks.csv to “convert” it.

Mistaken belief: the file is now a CSV.

Why it goes wrong: only the label changed. The content is still spreadsheet data, so software that expects plain text shows garbled characters or an error.

Correction: open the original and use the save or export option to write a CSV. The software rewrites the content, not just the name.

Check yourself

1. Which extension would you expect on a fixed-layout document for sharing?

Show answer

.pdf.

2. The name is timetable.docx.pdf. What type does the system treat it as, and why?

Show answer

A PDF, because the last extension is the one used. The .docx is just part of the base name.

3. True or false: a CSV can hold a formula such as =B2*C2 that recalculates when opened.

Show answer

False. A CSV stores plain values only. The formula result may be saved as a number, but the formula itself is lost.

Where this leads next

Now look at exporting without losing required content. Return to the module overview if you need the order, and use the mixed practice set to test yourself.

If confusing file types keeps costing you time, an ICT teacher working one-to-one can check your habits on live tasks.

Questions people ask

Does renaming .txt to .csv convert the file?

No. Renaming changes only the label. The content stays exactly as it was. If the text inside is already comma-separated values, it may open correctly as a CSV, but if it is not, the file will not work. Real conversion needs an export or save-as step in software.

Why can I not see extensions on my computer?

Many systems hide known extensions by default. There is usually a setting in the file manager's view options to show them. Showing extensions is useful for ICT practice because you can then check what you are actually opening and saving.

What is a double extension?

A name such as report.docx.pdf has two extensions. Only the last one normally counts, so the system treats it as a PDF. Double extensions usually come from typing the extension into a save box that already adds one, and they cause confusion when marking.

Updated:

Your next step

If file types still feel like labels you guess at, a one-to-one teacher can walk through real files with you until the pattern is automatic.

Paid one-hour trial at your assigned teacher’s confirmed rate, starting from RM80. You agree the teacher’s hourly rate before the trial, and ongoing lessons continue at that same rate. The schedule is arranged with your teacher after the trial.

Tuition is arranged with a parent or guardian. Send them this page on WhatsApp and they can enquire for you.

Parent or guardian? Enquire here

9,000+ students helped through our service