JSON to CSV Converter

Paste a JSON array or drop a .json file to get a CSV table that opens in Excel or Google Sheets. Nested objects are flattened into their own columns.

Updated
Runs in your browser. Your data is not uploaded.

Excel-safe adds a UTF-8 byte order mark so Excel reads accents correctly, and puts an apostrophe before cells that start with =, +, -, or @ to block formula injection.

Converts as you type for inputs up to 200 KB.

How to use the JSON to CSV Converter

  1. Paste your JSON into the input box, or upload or drag in a .json file up to 5 MB.
  2. Choose the Delimiter, and turn Include header row, Flatten nested objects, or Excel-safe on or off.
  3. Press Convert. Check the table preview, then press Copy or Download .csv.

How it works

  • Input shapes: an array of objects gives one row per object. A single object gives one row. An array of plain values gives one column named value.
  • Columns: every key found in any object, in the order it first appears.
  • Nested objects become dot-path columns, so {"address":{"city":"Lisbon"}} becomes a column named address.city.
  • Arrays inside an object are written into the cell as JSON text.
  • null values and missing keys give an empty cell.
  • Quoting follows RFC 4180. A cell that contains the delimiter, a double quote, or a line break is wrapped in double quotes, and any double quote inside it is doubled.
  • Excel-safe adds a UTF-8 byte order mark and puts an apostrophe in front of cells that start with =, +, -, @, a tab, or a carriage return, so a spreadsheet can't run them as formulas.

Examples

Input:

[{"id":1,"name":"Ana","address":{"city":"Lisbon"}},{"id":2,"name":"Ben","email":"[email protected]"}]

Output:

id,name,address.city,email
1,Ana,Lisbon,
2,Ben,,[email protected]

A value with a comma is quoted: [{"note":"Hello, world"}] gives a note column whose cell is "Hello, world".

When to convert JSON to CSV

JSON is how most APIs deliver data, but spreadsheets and many business tools expect CSV. Converting lets you:

  • Open an API response or database export in Excel or Google Sheets
  • Share data with people who don't work with code
  • Import records into a CRM, email tool, or database that accepts CSV

Comma or semicolon?

In countries where the comma is the decimal separator, such as Germany, France, and Brazil, Excel expects fields separated by semicolons. If your CSV opens with everything in one column, convert again with the semicolon delimiter.

Limitations

  • Input is limited to 5 MB.
  • Invalid JSON shows an error with the line and column. A top-level string or number gives "Expected an array or object".
  • The preview shows the first 100 rows. The copied or downloaded file contains every row.
  • Arrays inside objects stay as JSON text in one cell. They are not split into extra rows.

Frequently asked questions

What JSON structure do I need?

An array of objects works best, with each object becoming one row. A single object becomes a one-row CSV.

How are nested objects handled?

They are flattened into columns with dot notation, so {"address":{"city":"Lisbon"}} becomes a column named address.city.

Will the CSV open correctly in Excel?

Yes. For non-English characters, turn on "Excel-safe" so Excel detects UTF-8. In regions where Excel expects semicolons, pick the semicolon delimiter.

Is my data uploaded?

No. The conversion runs in your browser.

Often used together with the JSON to CSV.