CSV to JSON converter
Convert CSV to JSON in your browser: nothing is uploaded, there is no limit on the size, and the separator is detected automatically. Paste an export from Excel, Google Sheets or a database and get a JSON array.
How it works
-
Paste your code
Paste the code in the left box or open a file. No code to hand? Click Example.
-
Instant result
The result appears as you type. If there is an error, you see the line and character.
-
Copy or download
Copy the result with one click or save it as a file for your editor or project.
How does CSV become JSON?
Every row becomes an object and the first row supplies the keys. Values in quotes may contain the separator, quotes (written as "") and even line breaks. Turn off First row contains column names to get an array of arrays instead.
Numbers and true/false
With Recognise numbers and true/false, 34 becomes a number and true a boolean. Values with a leading zero, such as the postcode 0123, stay text so the zero isn't lost. Empty cells become null. Decimal commas (41,5) are read as numbers too.
Comma, semicolon or tab?
European versions of Excel often save CSV with a semicolon, because the comma is used for decimals there. Automatic looks at the first line and picks the separator that makes sense. Going the other way? Use JSON to CSV.
Problems you may run into
- Everything ends up in one column. The separator was not recognised. Choose it yourself: comma, semicolon or tab.
- Strange characters at the start of the first key. Some exports start with an invisible byte-order mark. Remove it, or copy the text from the file in an editor.
- Dates. A date such as
12-09-2026stays text. JSON has no date type, so convert it in your code or write it as an ISO date (2026-09-12) in the sheet first. - Long numbers. Values with more than 15 digits, such as bank account or order numbers, can lose precision as numbers. Switch off number recognition to keep them as text.
Preparing a sheet
Give every column a unique, clean header: no spaces at the end, no duplicates, no empty header cells. Those headers become the keys in your objects, so Postcode is easier to use in code than Zip code (home).
From JSON to rows
To go back to a spreadsheet, JSON to CSV flattens the objects again. To check the result first, paste it into the JSON formatter, and convert it to configuration format with JSON to YAML.
Frequently asked questions
Why does my semicolon-separated file end up in one column?
Then automatic detection picked the comma. Select the semicolon manually.
Are numbers converted to JSON numbers?
Yes, when recognition is on. Values with a leading zero, such as 0123, stay text so the zero is kept.
What happens to empty cells?
They become null.
Is my data uploaded?
No. The conversion happens in your browser and your CSV never leaves your device.