WhyCrashed

.csv · text/csv

What is a .csv file?

Comma-Separated Values

About the format

A .csv file is tabular data as plain text: one row per line, columns separated by commas (or, in much of Europe where the comma is the decimal separator, by semicolons — the first thing to check when a CSV opens as one giant column). It's the universal export/import format for spreadsheets, databases, banks and every reporting tool. Excel opens CSV on double-click but is also the source of most CSV grief: it silently reformats things (long numbers to scientific notation, anything date-like to dates, leading zeros stripped from phone numbers and postcodes) and saves back with your locale's delimiter. For inspection without side effects, a text editor shows the truth. One genuine security note: spreadsheet formula injection — a cell starting with =, +, - or @ in a CSV from an untrusted source can execute as a formula when opened in Excel, an old trick for exfiltration prompts. Excel warns about this; the caution costs nothing.

How to open a .csv file

Windows

  • Excel (convenient, but reformats)
  • Notepad (shows the real content)
  • Power Query (controlled import)

macOS

  • Numbers, Excel, any editor

Linux

  • LibreOffice Calc, any editor

Is a .csv file dangerous?

Mostly no. From untrusted sources, watch the formula-injection quirk when opening in a spreadsheet app.

Related file types

.xlsx.json.txt

Not sure what a file is? Check its bytes.

File names lie; magic numbers don't. Drop any file into the identifier — nothing is uploaded.

Identify a file →