JSON to CSV Converter — Convert JSON to CSV Online Free

JSON to CSV Converter — Convert JSON to CSV Online Free

JSON to CSV Converter — Convert JSON to CSV Online Free

A JSON to CSV converter turns structured JSON data into a plain spreadsheet table that Excel, Google Sheets, and every data tool can open. Paste an array of objects — or a single object — and this free converter flattens nested fields, handles commas and quotes correctly, and gives you a clean .csv file to download. Everything runs in your browser; nothing is uploaded anywhere.

What Is a JSON to CSV Converter?

A JSON to CSV converter takes data written in JSON — the format almost every API returns — and rewrites it as CSV, the plain-text table format that spreadsheets understand. JSON is built for machines: keys and values nested inside brackets and braces. CSV is built for people working in a table: one row per record, one column per field, separated by commas. Converting between the two is a daily job for anyone who exports data from an API, a database, or a web app and needs to open it in Excel or Google Sheets, share it with a colleague, or load it into a reporting tool.

This page is a free JSON to CSV converter that works entirely in your browser. Paste your JSON, pick a delimiter, and click Convert. Nested objects are flattened into dotted column names such as address.city, lists of simple values are joined with a semicolon, and any value that contains a comma, a quote, or a line break is wrapped in quotes exactly the way the CSV standard (RFC 4180) requires — so Excel and Sheets open the result without splitting a single field in the wrong place.

How to Convert JSON to CSV Online

  1. Paste your JSON into the input box at the top of this page, or click "Load sample" to try it with a small list of products.
  2. Choose your delimiter. Comma is the default and works in Excel and Google Sheets. Pick semicolon if your data uses commas as decimal separators, or tab/pipe for tools that expect them.
  3. Keep "Flatten nested objects" on unless your JSON is already flat. Flattening turns {"address": {"city": "Lahore"}} into a column called address.city instead of dropping the data.
  4. Click "Convert to CSV". The CSV appears in the output box, together with the row count, column count, and file sizes.
  5. Copy or download. Use "Copy result" to paste into a spreadsheet, or "Download .csv file" to save it and open it directly in Excel or Google Sheets.
  6. Check errors first. If your JSON is invalid, the tool shows the parser's exact error instead of guessing. Fix the error — usually a missing comma, a trailing comma, or single quotes instead of double quotes — and convert again.

How Nested JSON Becomes Flat Columns

CSV has no nesting: it is a flat grid of rows and columns. So a converter has to decide what to do with values that are objects or arrays inside your JSON. This tool uses three simple rules, and it applies them the same way every time:

JSON valueWhat the CSV getsExample
Nested objectFlattened into dotted columns{"address": {"city": "Lahore"}} becomes a column address.city with value Lahore
Array of simple valuesJoined with "; " in one cell["red", "blue"] becomes red; blue
Array of objectsKept as compact JSON text in one cell[{"size": "M"}] stays as JSON text, quoted so the commas inside it cannot break the row
Missing key in one rowEmpty cellIf only one product has a discount, the other rows get a blank cell in that column
null, true, false, numbersWritten as-isnull becomes an empty cell; true and numbers are written plainly

If you switch flattening off, nested objects are kept as compact JSON text in a single cell instead — useful when you want to keep the original structure and only convert the top level. The column list is built from every key found in any row, in the order the keys first appear, so no field is ever silently dropped because it only shows up in the last record.

JSON vs CSV — When to Use Each Format

FeatureJSONCSV
StructureNested objects and arrays, any depthFlat rows and columns only
Best forAPIs, apps, config files, storing dataSpreadsheets, reports, importing into tools
Opens inCode editors, browsers, programming languagesExcel, Google Sheets, LibreOffice, databases
Human readingReadable after formatting, but noisy with bracketsReads like a table at a glance
Data typesNumbers, strings, booleans, null, nested valuesEverything is text — types are guessed on import
File sizeLarger — keys repeat in every recordSmaller — the header row holds the keys once

Neither format is "better" in general. Keep JSON when a program will read the data back, and convert to CSV when a person needs to look at it, sort it, filter it, or hand it to a spreadsheet. If you need to go the other way, the JSON Formatter on this site formats and validates JSON before you convert it.

When to Use a JSON to CSV Converter

  • API exports. An API returns a list of orders, users, or products as JSON. Convert it to CSV and open it in Excel to sort, filter, and total the numbers.
  • Shop and order data. Product lists, prices, and stock levels exported as JSON become a price list or inventory sheet in one click.
  • Reports for non-technical colleagues. A CSV opens in any spreadsheet; a JSON file does not. Convert before you share.
  • Importing into another tool. Email tools, CRMs, and accounting software almost always accept CSV uploads and almost never accept raw JSON.
  • Quick data checks. A spreadsheet makes it easy to spot a missing price, a duplicate row, or a wrong date that is hard to see inside nested JSON.
  • Cleaning data before analysis. Convert, fix the values in the sheet, and you have a clean table ready for charts or a database import.

Worked Example

Here is a real example, converted with this page's own logic using the comma delimiter and flattening on. The byte counts below were produced by running the converter on this exact input — nothing is estimated.

Before — JSON, 449 bytes, 3 products:

[
  {"id": 1, "name": "Winter Hoodie", "price": 2499, "inStock": true,
   "sizes": ["S", "M", "L"], "address": {"city": "Lahore", "area": "DHA"}},
  {"id": 2, "name": "Wool Shawl, Pashmina", "price": 1999, "inStock": false,
   "sizes": ["One Size"], "address": {"city": "Karachi", "area": "Clifton"}},
  {"id": 3, "name": "Fleece Jacket", "price": 2899, "inStock": true,
   "sizes": ["M", "L"], "address": {"city": "Lahore", "area": "Johar Town"}}
]

After — CSV, 7 columns, 3 rows:

id,name,price,inStock,sizes,address.city,address.area
1,Winter Hoodie,2499,true,S; M; L,Lahore,DHA
2,"Wool Shawl, Pashmina",1999,false,One Size,Karachi,Clifton
3,Fleece Jacket,2899,true,M; L,Lahore,Johar Town

Notice the details that matter: the nested address object became two columns (address.city and address.area), the size lists became single cells joined with "; ", and the second product's name — which contains a comma — is wrapped in quotes so Excel reads it as one cell, not two. The header row holds all seven column names, and every row has exactly seven fields.

JSON to CSV Converter tool in action: product JSON converted to CSV, 3 rows and 7 columns

Frequently Asked Questions

Is my JSON uploaded anywhere?

No. This JSON to CSV converter runs entirely in your browser. Your data never leaves the page, is never sent to a server, and is never stored. You can disconnect from the internet after the page loads and the converter will still work.

What JSON shapes can I convert?

An array of objects is the ideal input — each object becomes one row. A single object becomes one row. An array of simple values (numbers or strings) becomes a single column called value. An array of arrays becomes one column per position. If your JSON is an object that wraps the array — for example {"products": [...]} — the tool detects the first array inside it and converts that, so you do not have to cut the wrapper out by hand.

Why does my CSV open wrong in Excel?

Two usual causes. First, the delimiter: if your Windows region uses semicolons as the list separator, Excel expects semicolon-delimited files — pick "Semicolon" here and convert again. Second, the file encoding: this tool downloads UTF-8, which Excel on older Windows versions sometimes reads as garbled text for non-English characters. In that case open the file in Google Sheets (which reads UTF-8 correctly) or use Excel's "From Text/CSV" import and choose UTF-8.

How are commas and quotes inside values handled?

Exactly as the CSV standard requires. A field that contains the delimiter, a double quote, or a line break is wrapped in double quotes, and any double quote inside it is doubled (" becomes ""). That is why "Wool Shawl, Pashmina" survives as one cell in the example above. Fields without special characters are left unquoted, which keeps the file small and readable.

What happens to numbers, booleans, and null?

Numbers and booleans are written plainly (2499, true). A null becomes an empty cell, and a missing key in one row also becomes an empty cell — the row still keeps the right number of columns. One warning: very long numbers such as order IDs can lose precision or turn into scientific notation in Excel. If an ID must stay exact, open the CSV with the Text Import Wizard and set that column to Text.

Is there a size limit?

There is no server limit, because there is no server — but your browser still has to hold the data in memory. Files up to a few megabytes convert instantly. For very large exports (tens of megabytes or hundreds of thousands of rows), a desktop tool or a small script will be faster and safer than any browser converter.

Privacy note: this JSON to CSV converter runs entirely in your browser. Your data is processed locally on your device and is never uploaded to any server, stored, or shared with anyone.

Free online JSON to CSV converter by AIToolsForBloggers. Your JSON never leaves your browser.

Featured on LaunchNest