JSON to CSV converter
Convert a JSON array to CSV format with auto-generated headers from object keys. Values with commas or quotes are properly escaped. Download as a .csv file ready for Excel or Google Sheets.
JSON array input
CSV output
How JSON to CSV conversion works
The tool takes a JSON array of objects. The column names come from the keys of the first object, and each object becomes one row. Values that contain commas, quotes or line breaks are wrapped in double quotes, with inner quotes doubled, as RFC 4180 describes.
Example
[{"name":"Ada, Lovelace","city":"London"},{"name":"Ben","city":"Leeds"}]
becomes:
name,city
"Ada, Lovelace",London
Ben,Leeds
Limitations
- Only the keys of the first object become columns. A key that appears only in later objects is left out.
- Nested objects are written as
[object Object]. Flatten them before converting. - The input must be a JSON array. A single object is rejected with an error.