Filenames
A filename is an identifier for the file. It should distinguish a file from other files and give some idea what the file contains.
“National_Unemploment_2008_2009.csv”
“Consumer price index report 2015.pdf“
“2019-gross-national-income.xlsx”
“Transport emissions graph.jpg”
Filenames have two main parts:
- Name – a name should describe the file’s contents. It can be changed without affecting the file.
- Extension – this describes what type of file it is and what software can open it. It is recommended not to change this.
Some common file extensions include:
- .doc – Microsoft Word document
- .txt – text file
- .jpg – image file
- .csv – Comma separated value file
- .xlsx – Excel file
Use of filenames
Fact checkers often download multiple data files locally to their computer where they will perform their own analysis.
Good filenames can help with:
- Finding the file they want amongst a list of other files (perhaps on their desktop)
- Have a similar name to related files
- Not having to open files to have an idea of what they contain
Filename conventions
Every organisation’s datasets are different and often need their own file name conventions.
These don’t need to be a long list of strict rules, but just some best practices and good advice to help people find the files they need.
Examples of some types of filename guidance:
- Avoid dots or special characters
- Have a maximum file length
- Include a date in the ISO 8601 format: YYYY-MM-DD
- Not include hard to understand acronyms
- Avoid vague terms
A guide of your organisation’s filenames should be available on your website for easy reference.
Guidance elsewhere
We’ve found these examples on guidance for naming files which may be useful in creating your own guidance.
- Best practices for file naming | Stanford Libraries
- Research Guides: Research Data Management at Princeton: File naming and structure
- Datasets - ONS guidance for dataset titles
- Best Practices for File Naming – Records Express
- Organising your data | Research Data Management - Cambridge Research
- Filename - Wikipedia
- Filename extension - Wikipedia