JSON to CSV Converter Online
Paste a JSON array and get CSV that opens cleanly in Excel or Google Sheets, with the quoting done properly so commas and quotes inside values do not corrupt the file.
How it works
The reason a JSON to CSV converter needs to exist is that spreadsheet software cannot open JSON. When you need to hand someone a data set they will actually open, CSV is the format they can read without asking you for anything.
Most of the work is quoting. RFC 4180 says a field containing a comma, a double quote, or a newline must be wrapped in double quotes, and a double quote inside such a field is written twice. A value like Lovelace, Ada becomes "Lovelace, Ada", and a value containing a quote becomes "said ""hi""". Getting this wrong does not fail loudly — it shifts every column after the bad one, which is far worse than an error because the file still opens and looks plausible.
The header row is the union of every key across every object in the array, in the order they are first seen. Exporting only the keys present on the first object is a common bug: you get a header that silently omits a column and a spreadsheet with no complaint at all.
Nested objects are flattened to dotted headers, so an object with an address containing a city produces an address.city column. CSV has no nesting of its own, and dotted headers keep the export readable while staying reversible — the matching CSV to JSON tool expands them back into nested objects, so a round trip returns your original shape.
If your spreadsheet is a European locale, switch the delimiter to a semicolon. Excel in most of the world treats a comma as a decimal separator, and a comma-delimited file of numbers opens with the wrong number of columns.
Use the JSON to CSV Converter
Paste json on the left to see the result.Runs entirely in your browser — nothing you paste is uploaded or logged.
Worked examples
Real input and the exact output this page produces.
Example 1
JSON
[{"id":1,"name":"Ada","role":"admin"},{"id":2,"name":"Grace","role":"dev"}]
CSV
id,name,role
1,Ada,admin
2,Grace,dev
Example 2
JSON
[{"name":"Lovelace, Ada","note":"said \"hi\""}]
CSV
name,note
"Lovelace, Ada","said ""hi"""
Example 3
JSON
[{"id":1,"address":{"city":"London"}}]
CSV
id,address.city
1,London
Frequently asked questions
Will commas inside my values break the columns?
No. Any field containing a comma, a quote or a newline is wrapped in double quotes and embedded quotes are doubled, following RFC 4180.
What if the objects have different keys?
The header is the union of all keys across all objects, in first-seen order. Nothing is dropped, and rows with a missing value simply get an empty cell.
How are nested objects handled?
They are flattened into dotted headers such as address.city. The CSV to JSON tool reverses this, so a round trip returns the original nested shape.
Why would I want semicolons instead of commas?
Excel in most European locales treats a comma as a decimal separator. A comma-delimited file of numbers opens with the wrong number of columns there, so a semicolon is the safer delimiter.
What happens to null values?
They become an empty field, and CSV cannot tell an empty field apart from a genuinely empty string. Converting back gives an empty string in both cases. This is a limitation of the format, not of the conversion.
Related tools
Others doing similar work.