JSON1 / JSON to CSV
JSON to CSV
Flatten a JSON array into CSV. Nested objects become dotted columns, sparse records still line up, and cells containing delimiters are quoted.
Processed locally·Your data never leaves your device
InputJSON
ReadyOutputCSV
Converted output appears here as you type.
Good to know
- Arrays of plain values share one cell, joined with "; ".
About this tool
CSV is what spreadsheets and most data-analysis tools import, so this is the conversion to reach for when an API response needs to go to someone who works in Excel, Numbers, or Sheets.
JSON is a tree and CSV is a grid, so nesting has to be flattened: a nested object becomes dotted column names like address.zipCode. Records that are missing a field still line up under the right headers, and any cell containing your delimiter, a quote, or a newline is quoted so it survives the round trip.
- My JSON is a single object, not an array. Why the error?
- CSV rows are records, so the input needs to be an array of objects. Wrap a lone object in brackets to get a one-row file.
- Why is a cell starting with = or + quoted?
- Spreadsheets treat a leading
=,+,-, or@as the start of a formula. Quoting those cells keeps a value like-5or=SUMas text instead of something the spreadsheet tries to evaluate. - What happens to an array of plain values?
- It shares one cell, joined with a semicolon and a space, since there is no column to spread it across. An array of objects is flattened by index instead.