How to convert JSON to CSV
- Paste your JSON, choose a
.jsonfile, or drag it onto the input box. - Decide how nested objects and arrays should appear in the CSV.
- Untick columns you don't need and reorder the rest.
- Pick the delimiter and line endings your target program expects, then copy or download the CSV.
Example
Input:
[
{ "id": 1, "user": { "name": "Ana" }, "tags": ["a", "b"], "note": null },
{ "id": 2, "user": { "name": "Ben" }, "tags": [] }
] Output with the default settings (flatten, arrays as JSON text):
id,user.name,tags,note
1,Ana,"[""a"",""b""]",
2,Ben,[], How values are written
| In the JSON | In the CSV |
|---|---|
| String | The text, quoted only if it contains the delimiter, a quote or a line break |
| Number | Exactly as written in the JSON (no rounding, no reformatting) |
true / false | true / false |
null | Empty cell, or the text null if you choose |
Empty string "" | Empty cell |
| Key missing from a record | Empty cell |
| Array | JSON text such as ["a","b"], or one column per item |
| Empty object or array | {} or [], so it is not lost |
With the default settings, null, an empty string and a missing key all produce an empty cell. Choose "Write null as the text null" if you need to tell them apart.
Columns
The column list is the union of every key in every record, in the order keys are first seen. A record that lacks a key simply has an empty cell in that column, so no property is dropped. Keys such as __proto__ or constructor are treated as ordinary column names.
If flattening would put two different fields into the same column — for example a key literally named a.b and a nested {"a": {"b": …}} — conversion stops and lists the clash. Choose a different separator or keep nested values as JSON text.
Limitations
- The JSON must be strictly valid: double-quoted strings, no comments, no trailing commas. Errors show the line and column.
- Top-level arrays of plain values or of nested arrays are not converted in this version.
- JSON Lines (one object per line) is not supported yet.
- If an object repeats a key, the last value is used, as standard JSON parsers do, and you are warned.
- Maximum input size is 50 MB. Very deep nesting (over 1,000 levels) is rejected.
Frequently asked questions
What JSON structure does this accept?
An array of objects, where each object becomes one CSV row. A single object is also accepted and becomes one row. If your records are inside a wrapper object, such as {"data": [...]}, choose that key under "Records".
How are nested objects handled?
You choose. "Flatten" turns {"user": {"name": "Ana"}} into a user.name column. "Keep as JSON text" puts the whole nested value into one cell as JSON. If flattening would make two different fields share a column name, the converter stops and tells you instead of overwriting data.
Will long numbers or IDs be rounded?
Not by the converter: numbers are copied into the CSV exactly as they are written in your JSON, including values like 12345678901234567890. Be aware that Excel keeps only 15 significant digits when it opens a CSV, so it may display such numbers rounded.
Why does Excel show strange characters in my CSV?
Older versions of Excel assume a legacy encoding unless the file starts with a UTF-8 byte order mark. Enable "Add UTF-8 BOM" before downloading if accented letters or symbols look wrong in Excel.
What does spreadsheet-safe export do?
Cells that start with =, +, -, @ or a tab can be run as formulas when a CSV is opened in a spreadsheet. With this option on, those cells get an apostrophe in front so they are shown as text. Plain numbers like -12 are left alone. It changes the exported text, so leave it off if the CSV is for another program.
Last updated .