Kadben

Convert JSON to CSV

Choose a JSON file or paste JSON to get a CSV file. Nested objects and arrays are flattened by the fixed rule described on this page.

Runs in your browser. Nothing is uploaded.

JSON to CSV

Input
Options

The result appears here.

How to use it

  1. Choose a JSON or JSON Lines file, drop it on the box, or paste JSON; the result appears at once.
  2. Check “Rows from”: a top-level array is used as is, otherwise the largest array of objects. Choose another one if needed.
  3. Choose the delimiter and decimal separator that your spreadsheet program expects, and keep the UTF-8 BOM if you open the file in Excel.
  4. Download the .csv file or copy the result.

Rules and limits

The array rule: nested data in columns

How CSV is written

Questions and answers

How are nested objects and arrays flattened?

Nested objects get dotted column names, such as customer.city. Arrays get numbered columns starting at 0: tags.0, tags.1, and for arrays of objects items.0.sku, items.1.sku. An empty object or array gives an empty cell. Columns appear in the order in which they are first found.

Which delimiter should I choose for Excel?

Excel on Windows opens CSV files with the list separator of the region settings. In the US and the UK that is a comma; in Germany, France, Spain and many other countries it is a semicolon, with a comma as the decimal separator. Choose the delimiter and decimal separator to match.

Why do umlauts or accents look wrong in Excel?

Excel on Windows opens a CSV file without a byte order mark in the system’s legacy encoding instead of UTF-8. Keep the option “UTF-8 BOM for Excel” on: it adds three bytes at the start that tell Excel the file is UTF-8.

Can I convert JSON Lines?

Yes. A file with one JSON value per line (JSON Lines, NDJSON) is read as a list, and every line becomes a row.

Are very large numbers safe?

Browsers read JSON numbers as 64-bit floating-point values, so whole numbers above 9,007,199,254,740,991 are rounded before conversion. The tool warns when it finds one. Keep such IDs as strings in quotes in the JSON.

Related tools