How to use the CSV to JSON
- Paste CSV text or drop a .csv file exported from Excel, Sheets or a database.
- Check the delimiter (auto-detected from the first line: comma, semicolon, tab or pipe) and whether the first row is a header.
- Choose whether numbers and true/false should be detected or kept as strings.
- Copy or download the JSON.
Worked example
A quoted name and an empty cell
CSV
name,age,city Ada,36,London "Hopper, Grace",85,
JSON (number detection on)
[
{
"name": "Ada",
"age": 36,
"city": "London"
},
{
"name": "Hopper, Grace",
"age": 85,
"city": ""
}
]The comma inside the quotes stays part of the name. The trailing empty field becomes an empty string; with type detection off, ages would be "36" and "85".
Type detection: what changes
| CSV cell | Detection on | Detection off |
|---|---|---|
| 36 | 36 | "36" |
| true | true | "true" |
| 007 | "007" (leading zero kept as text) | "007" |
| 1e3 | 1e3 (a JSON number, digits kept as written) | "1e3" |
| (empty) | "" | "" |
Delimiters and regional exports
Excel in many European locales saves "CSV" with semicolons because the comma is the decimal separator there. The delimiter is auto-detected from the first line; if every row still comes out as a single key, set it to semicolon by hand. Tab-separated files (.tsv) work the same way with the tab delimiter.
Values that should stay strings
ZIP codes, phone numbers, product codes and long IDs look numeric but are identifiers. Cells with a leading zero such as 02134 stay strings. Long numeric IDs are written with every digit, but JSON.parse in JavaScript will round them beyond 2^53. Turn type detection off when in doubt and convert specific fields in code.
Duplicate header names are renamed automatically (id, id_2), and an empty header becomes column_N, so no value is lost.
CSV to JSON FAQ
How do I convert an Excel sheet to JSON?
In Excel choose File > Save As > CSV UTF-8, then paste or drop the file here. Each sheet must be saved separately.
What if my CSV has no header row?
Turn off the header option; the output is then an array of arrays, one inner array per row. To get objects instead, add a header line to the CSV yourself.
Why does my CSV to JSON output have one huge key?
The delimiter is wrong. A semicolon- or tab-separated file read as comma-separated puts the whole line in one field. Pick the matching delimiter.
How are line breaks inside a cell handled?
A field wrapped in double quotes may contain line breaks; the parser keeps them inside the value as \n instead of starting a new row.
Can I get nested JSON from CSV?
By default the objects are flat. If your headers use dotted names like address.city or tags.0, turn on the unflatten option to rebuild nested objects and arrays (empty cells are skipped).

