What Is CSV?
CSV (Comma-Separated Values) is a plain-text format for tabular data: each line is a row, and fields within a row are separated by commas. Simple in concept, CSV is deceptively tricky in practice — quoting rules, line endings, encoding, and delimiter variations have tripped up every developer at least once.
The One-Line Definition
CSV is a plain-text format where each line represents a data record and fields within each record are separated by commas. Documented (but not strictly standardised) in RFC 4180.
A CSV Example
id,name,email,active 1,Ada Lovelace,ada@example.com,true 2,"Smith, John",john@example.com,false 3,Grace Hopper,"grace@example.com",true
The Rules (RFC 4180)
CSV vs TSV
The Encoding Gotcha
CSV has no encoding header. Files exported from Microsoft Excel may use Windows-1252 encoding (breaking non-ASCII characters) or UTF-16 with a BOM. Always specify UTF-8 when exporting and validate the encoding before parsing.
Convert CSV Now
CSV to JSON → · JSON to CSV → — all conversions run in the browser.
Frequently Asked Questions
How does CSV handle commas or newlines inside a field?
Wrap the field in double quotes: "Smith, John". A double-quote inside a quoted field is escaped by doubling it: "He said ""hello""".
What is the difference between CSV and TSV?
TSV uses a tab as delimiter instead of a comma. Tabs appear less often in data than commas, making TSV less ambiguous for text-heavy data.
How do I convert CSV to JSON online?
Paste your CSV into SmartDevBox. The CSV to JSON tool uses the header row as property names and returns a JSON array — all client-side.