↑↓ to move ↵ to open Esc to close Browse all tools

Files guide

File Naming Conventions: Dates, Versions and What to Avoid

Good file names sort in the right order, open on every computer and tell you what is inside without opening the file. Three habits do most of the work: dates with the year first, version numbers with a leading zero, and no characters that some system rejects. Here are the rules from Microsoft, Apple and two university research data guides, a worked project folder and a checklist.

What a good file name contains

The research data guides at Stanford Libraries and Harvard Medical School agree on the basics: be consistent and descriptive, put the most important information first, and write the convention down in a README file next to the data. A name usually combines a few of these parts:

  • a date, year first
  • a project or client name
  • what the file is: contract, notes, invoice, hero image
  • a version number at the end
  • initials, when several people edit the same files

Harvard's good examples look like 20160104_ProjectA_MeetingNotes_SmithE_v2.docx. Its poor examples are the names everyone has on their desktop: "Meeting notes Jan 17.doc" and "Final FINAL last version.docx". Harvard suggests keeping names to about 40 to 50 characters; if you need to record more than that, keep it in a spreadsheet instead of the name.

Dates: year first, always

Harvard's guide points out that names sort character by character. If the date starts with the month, a plain sort puts the years out of order. Sorted, the month-first names come out as 03-14-2026_notes.txt, 11-02-2025_notes.txt, 12-01-2025_notes.txt: March 2026 lands before November 2025. The same dates written year first sort as 2025-11-02_notes.txt, 2025-12-01_notes.txt, 2026-03-14_notes.txt, which is also the order in time.

Harvard recommends YYYYMMDD and accepts YYYY-MM-DD for version dates, both forms of ISO 8601. Stanford recommends YYYYMMDD or YYMMDD. The hyphenated form is easier to read, the compact one is shorter; pick one and keep it. The ISO 8601 date format guide covers the full standard, including times. When the date in a name is a deadline rather than a creation date, work it out first: a letter received on 2026-10-26 that must be answered within 30 days is due on 2026-11-25, which the add or subtract days tool gives you without counting on a calendar.

Versions: v01, not v1, and never "final"

Harvard puts the version at the end of the name and pads it with a zero: v01, v02. The reason is the same character-by-character sort. Without padding, a plain sort gives report_v1.docx, report_v10.docx, report_v11.docx, report_v2.docx. With padding it gives report_v01.docx, report_v02.docx, report_v10.docx, report_v11.docx. Stanford gives the same advice for any sequence number: 001, 002, up to 010 and 011.

Three versioning schemes work well:

SchemeExampleGood for
Version numberproposal_v03.docxDrafts of one document
Date of the versionproposal_2026-10-26.docxFiles revised on a schedule
Date plus version2026-10-26_proposal_v03.docxSeveral drafts on the same day

"Final" is not a version. The file called final is rarely the last one, which is how "Final FINAL last version.docx" happens. When a version is approved, copy it into a separate folder for finished work and keep its number.

Characters to avoid, and why

Windows, macOS and the guides each rule out different characters. Avoid all of them and a name is valid on both systems and follows both guides.

CharacterProblemSource
< > " | ? *Reserved characters in Windows file namesMicrosoft
: (colon)Reserved in Windows; a Mac name cannot include it eitherMicrosoft, Apple
/ and \Path separators; both reserved in Windows, and some Mac apps reject a slashMicrosoft, Apple
SpaceBoth guides say no spaces; use _ or - insteadStanford, Harvard
. at the startA Mac name cannot start with a period; on many systems it marks a hidden fileApple, Stanford
Space or . at the endThe Windows shell does not support itMicrosoft
~ ! @ # $ % ^ & ( ) ` ; , [ ] { } 'On both guides' lists of special characters to avoidStanford, Harvard
Control characters 0 to 31Not allowed in Windows file namesMicrosoft

Windows also reserves a set of names: CON, PRN, AUX, NUL, COM1 to COM9, LPT1 to LPT9. Microsoft says to avoid them even with an extension, because NUL.txt is treated the same as NUL. And Microsoft warns not to assume case sensitivity: Windows treats OSCAR, Oscar and oscar as the same name, while some other file systems do not. Writing names in lowercase avoids two files that differ only by case.

Path length is the other limit. In Windows editions before Windows 10 version 1607 the maximum path is 260 characters, and later versions need a registry or Group Policy change to lift it. The limit covers the whole path, so a long name six folders deep fails where the same name near the top works.

A worked project folder

Here is one website project named with these rules. Folders get a two-digit number so they stay in working order, dates come first where the date matters, and versions sit at the end.

2026_website-redesign/
  README.txt
  01_admin/
    2026-10-05_contract_signed.pdf
    2026-10-26_invoice_0001.pdf
  02_drafts/
    homepage-copy_v01.docx
    homepage-copy_v02.docx
    homepage-copy_v03_tk.docx
  03_images/
    hero_1920x1080_v02.jpg
    team-photo_v01.jpg
  04_final/
    2026-11-20_homepage-copy_v03.pdf

The README says what the parts mean: dates are YYYY-MM-DD, versions are two digits, initials at the end mark who edited a draft. Turning a title like "Homepage Copy" into homepage-copy is what the slug generator does, in bulk if needed, and the case converter switches a list of names to snake_case or kebab-case. To fix many existing names at once, paste the list into find and replace, replace spaces with hyphens, and use the regular expression _v(\d)\. with the replacement _v0$1. to turn v1 into v01.

Write the rules down

Both university guides end with the same advice: document the convention in a README file and keep it with the files. It takes five minutes and saves the question "what does tk mean" a year later. A README for the folder above can be this short:

Naming rules for 2026_website-redesign
Pattern:   YYYY-MM-DD_what_vNN_initials.ext
Dates:     year first, with hyphens (2026-10-26)
Versions:  two digits at the end (v01, v02); approved
           versions are copied to 04_final
Words:     lowercase, hyphens inside a part,
           underscores between parts
Initials:  who edited a draft (tk, js)

Put the most important part first. Harvard notes that the order of the parts decides how the files sort, so a project archive sorted by date starts with the date, while a folder of contracts per client might start with the client name. Whatever you choose, apply it to new files from today and rename old ones only when you touch them.

Checklist

  • Dates written year first, the same way in every name.
  • Version numbers padded with a zero, at the end, no "final".
  • Only letters, digits, hyphens and underscores, plus one period before the extension.
  • No space, no colon, no slash, no period at the start or end.
  • No Windows reserved names such as CON, NUL or COM1.
  • Lowercase, so two names never differ only by case.
  • About 40 to 50 characters, with the most important part first.
  • A README.txt in the top folder that explains the scheme.

Frequently asked questions

Should I use underscores or hyphens in file names?

Both are fine; the Stanford and Harvard guides list underscores, hyphens and camel case as alternatives to spaces. A common pattern is underscores between the parts of a name and hyphens inside a part, as in 2026-10-26_meeting-notes_v02.docx. Pick one rule and write it in a README.

What date format is best in a file name?

Year first. Harvard recommends YYYYMMDD and accepts YYYY-MM-DD for version dates, both ISO 8601 forms; Stanford recommends YYYYMMDD or YYMMDD. With the year first, an alphabetical sort is also a chronological sort, which month-first dates never are.

Why does v10 sort before v2?

A plain sort compares names character by character, so v1 and v10 share the first two characters and v10 comes before v2 because the character 1 sorts before 2. Zero-padding fixes it: v01, v02 and v10 sort in the right order. Harvard recommends exactly that, v01 and v02.

Why can I not name a file CON or NUL on Windows?

They are reserved device names. Microsoft lists CON, PRN, AUX, NUL, COM1 to COM9 and LPT1 to LPT9 as names not to use, and says the same goes for those names followed by an extension, so NUL.txt is treated as NUL.

How long can a file name be?

Harvard suggests keeping file names to about 40 to 50 characters. Windows has a separate limit on the whole path: before Windows 10 version 1607 it was 260 characters, and later versions need a registry or Group Policy change to remove it. Deep folders with long names hit that limit first.

Sources