Convert JSON to CSV without uploading anything
JSON stores data as objects and lists that can sit inside each other, but a spreadsheet wants plain rows and columns. This JSON to CSV converter turns a JSON array of records into a CSV file for Excel, Google Sheets or any other program that reads CSV: one row per record and one column per field. Nested objects are flattened into columns of their own, you pick the delimiter and the columns, and you can check the result in a table before you download it.
The conversion runs in a background thread of your browser. Your JSON is never uploaded, so exports with customer data, orders or private API responses stay on your device, and the page stays responsive even with files of 50 MB or more. To tidy up or validate JSON first, use the JSON formatter. For the opposite direction, the CSV to JSON converter turns a spreadsheet back into JSON.
Which JSON you can convert
- An array of objects, like [{"name": "Ann"}, {"name": "Ben"}]. Every object becomes a row. Objects do not need the same keys: the columns are the union of all keys, in the order they first appear, and missing values stay empty.
- An object with a list inside, like the typical API answer {"data": {"items": [...]}}. The converter lists every array it finds under Rows from and starts with the largest list of objects.
- An object of objects, like {"u1": {...}, "u2": {...}}. Pick the one row per key option and the keys go into a column called key.
- JSON Lines, one JSON value per line, as described on jsonlines.org. Each line becomes a row.
- An array of arrays or plain values. Inner arrays become rows with columns named 0, 1, 2, and plain values go into a column called value. If the first inner array already holds the column names, switch off Header row.
If the JSON is invalid, you get the line and column of the first problem, a short explanation such as a trailing comma or a missing quote, and a button that jumps to the spot.
How nested objects and arrays become columns
| In your JSON | Setting | In the CSV |
|---|---|---|
| {"address": {"city": "Lyon"}} | Flatten to columns | Column address.city with Lyon |
| {"address": {"city": "Lyon"}} | Keep as JSON text | Column address with {"city":"Lyon"} |
| {"tags": ["red", "blue"]} | Keep as JSON text | Column tags with ["red","blue"] |
| {"tags": ["red", "blue"]} | Join values | Column tags with red, blue |
| {"tags": ["red", "blue"]} | One column per item | Columns tags.0 and tags.1 |
Values are written as plain text: true and false stay as words, null becomes an empty cell, and numbers keep the digits of your file. The JSON standard, RFC 8259, notes that software which reads numbers as 64-bit floating point values agrees exactly only on whole numbers up to 253 minus 1. Longer IDs can lose their last digits on the way. This converter copies every number with more than 15 significant digits straight from your text instead.
The CSV rules this converter follows
RFC 4180 says there is no formal specification for CSV and documents the format that seems to be followed by most implementations. With quotes set to Only where needed, the output follows it:
- A field that contains the delimiter, a double quote or a line break is wrapped in double quotes.
- A double quote inside a field is written twice, so say "hi" becomes "say ""hi""".
- Records end with CRLF, the line break RFC 4180 names. Choose LF if the program that reads the file expects it.
- The optional header line holds the column names, in the same format as the data rows.
RFC 4180 itself only speaks of commas. Semicolon, tab and pipe work the same way: the quoting rules simply apply to the delimiter you chose. Around every field puts quotes on all values, empty ones included.
Opening the CSV in Excel or Google Sheets
Microsoft support explains that Excel opens a UTF-8 CSV file normally when it was saved with a byte order mark (Opening CSV UTF-8 files correctly in Excel). That is what Add BOM for Excel does: it puts that invisible mark at the start of the downloaded file, so names like Zoë or São Paulo come through intact. The mark is an extra invisible character before the first column name, so switch it off when the file is meant for a script or a database rather than a spreadsheet. Copy CSV never includes it.
If Excel puts every value into column A, the delimiter does not match what your Excel expects. Download the file again with Semicolon and open it once more.
Text that starts with =, +, - or @ can run as a formula when a spreadsheet opens the file. The OWASP page on CSV injection recommends that no cell start with these characters, or with a tab or line break, and suggests putting a single quote in front. Guard against formulas does exactly that for text values, while real numbers like -5 stay numbers. Turn it on when the JSON comes from people you do not know, such as form entries.
How to use the JSON to CSV converter
- 1Paste your JSON, drop a .json file on the box or open one. The example shows how a typical file converts.
- 2Check Rows from, pick a delimiter and decide how nested objects and arrays should look.
- 3Open Choose and order columns to drop or move columns, and check the preview table.
- 4Download the .csv file or copy the CSV and paste it where you need it.
Frequently asked questions
Is my JSON uploaded anywhere?
No. The file is read and converted by your browser, in a background thread on your own device. Nothing is sent to a server, so you can convert customer lists, API responses and exports that should stay private. Copy link only shares your settings, never the data.
How are nested objects turned into columns?
Each nested value gets its own column, named by its path with dots, so {"address": {"city": "Portland"}} becomes a column called address.city. Objects inside objects keep going, like user.address.zip. If you would rather keep a nested object together, set Nested objects to Keep as JSON text and it lands in one cell as JSON.
What happens to arrays inside my records?
You choose. Keep as JSON text puts ["red","blue"] into one cell exactly as JSON. Join values writes red, blue with the separator you pick. One column per item spreads them out as tags.0, tags.1 and so on, counting from 0 like JSON does. Objects inside a joined array are written as JSON text.
My JSON is an object, not an array. Can I still convert it?
Yes. When the records sit inside an object, like {"data": {"items": [...]}}, the converter finds every list in it and picks the largest list of objects. Use Rows from to pick another one. An object whose values are all objects, like {"u1": {...}, "u2": {...}}, can become one row per key, with the key in its own column. Any other object becomes a single row.
Why do accents or emoji look broken when I open the CSV in Excel?
Microsoft support says Excel opens a UTF-8 CSV file normally when the file was saved with a byte order mark (BOM). Leave Add BOM for Excel switched on and download the file again. The mark is one invisible character at the very start of the file.
How large a file can it handle?
Files of 50 MB and more work, as long as your device has enough memory. The conversion runs in a background thread, so the page stays responsive while it works, and only the first 100 rows are drawn in the preview. Copy and Download always contain every row.
Are long numbers like IDs kept exactly?
Yes. Software that reads JSON numbers as 64-bit floating point values agrees exactly only on whole numbers up to 9,007,199,254,740,991, as the JSON standard RFC 8259 points out, so longer numbers can lose their last digits. This converter copies every number with more than 15 significant digits from your text exactly as it was written, so an ID like 12345678901234567890 comes out unchanged.