How to use the JSON to CSV Converter
- Paste a JSON array of objects or choose one local .json file up to 1 MiB.
- Choose comma, semicolon or tab, and decide whether nested objects and arrays should stay as JSON in one cell or cause an error.
- Keep formula-like string protection enabled unless you understand the import risk. Optionally add a UTF-8 BOM to the downloaded file.
- Press Convert to CSV. Review row/column counts, changed-string count and the output, then copy or download it. Cancel stops the worker and discards pending output.
How it works
The browser parses the source as JSON, then builds columns from all record keys in first-seen order. Each input object becomes one row. All fields are quoted, internal double quotes are doubled, and rows use CRLF line endings following the common CSV conventions described in RFC 4180.
Missing values and null both become empty cells; numbers and booleans become text. Nested objects and arrays either become compact JSON inside one cell or are rejected. There is no flattening or array-to-row expansion. Preserve the source JSON when its types or missing/null distinction matter.
Formula-like strings and headers are prefixed with an apostrophe by default. This changes their text and reduces a spreadsheet import risk; it is not a universal guarantee. Quoting alone does not prevent spreadsheet formulas. Use controlled text imports and do not enable untrusted formulas.
A dedicated worker loads only when conversion starts and is terminated on cancellation or after five seconds. Limits are 1 MiB input, 10,000 records, 200 columns, 200,000 cells, 32 nested levels and 8 MiB CSV. No input content is uploaded or saved in browser storage.
[{"id":"0012","name":"Ada, A."},{"id":"0013","name":"Bo"}]
"id","name"
"0012","Ada, A."
"0013","Bo"Worked example: a quoted name and a missing field
For [{"id":"0012","name":"Ada, A."},{"id":"0013"}], columns are id and name. The comma inside Ada's name stays in one quoted cell. The missing name becomes an empty cell; the identifier stays a string in the CSV text.
When a string starts with =SUM(A1:A2), the default protection adds an apostrophe. Check the reported change count. A numeric -12 is exported as a number-like cell; a string "-12" is treated conservatively as a formula-like string.
Limitations
- Only a nonempty JSON array of objects is supported. Extract a records array from an API wrapper first. CSV input, JSON Lines and scalar/array rows are unsupported.
- This is not schema validation, streaming data processing or a lossless typed interchange format. Duplicate JSON keys follow JSON.parse behaviour; decimal numbers use JavaScript floating-point precision. Unsafe integer values are rejected, so quote long identifiers in source JSON.
- Spreadsheet applications may reinterpret dates, identifiers and formula-like text. A BOM helps some encoding imports but does not preserve types or make formulas safe. Prefix protection changes data and can be undone by later saving/importing.
- Files over the stated limits fail clearly. Large or complex exports may reach the worker deadline. Original files are never overwritten; keep source copies.
Frequently asked questions
Can I convert nested JSON to CSV?
Yes, nested values can remain compact JSON in a single cell. This release does not flatten keys or create extra rows from arrays. Choose reject mode if your workflow requires flat data.
Why did my identifier lose its leading zero in Excel?
CSV does not prescribe spreadsheet column types. Import the identifier column as Text. Quote identifiers in the original JSON too; a JSON number cannot retain leading zeroes.
Are missing fields and null preserved differently?
No. Both export as empty cells. Preserve the source JSON when you need to distinguish them.
Does quoting CSV prevent formula injection?
No. Spreadsheet software may interpret quoted cells as formulas. The default apostrophe prefix mitigates suspicious strings, but is not a universal guarantee. Review and control imports.
Does this tool upload my JSON?
No. File reading and conversion happen locally in this browser. The page downloads its conversion worker, but sends no input content to a conversion server.