JSON to CSV Converter

Convert JSON arrays or objects to CSV with custom delimiters, header toggle, nested-key flattening, preview table, and one-click .csv download.

Updated

Share:
Read the guide: How to Convert JSON to CSV
Home/Converter Tools/JSON to CSV Converter

JSON to CSV Converter

Convert JSON arrays or objects to CSV with custom delimiters, header options, nested-key flattening, and instant preview.

Options

JSON Input

CSV Output

0 rows
0 columns
Comma (,)

Accepted input shapes

Array of objects: [{"a":1},{"a":2}]

Wrapped: {"data":[{"a":1},{"a":2}]}

Single object: {"a":1,"b":2} → one row.

Frequently Asked Questions

What is the JSON to CSV Converter?

The JSON to CSV Converter is a free online tool that convert json arrays or objects to csv with custom delimiters, header toggle, nested-key flattening, preview table, and one-click .csv download.. It runs entirely in your browser with no installation or sign-up needed.

What JSON shapes are accepted?

An array of objects, an object wrapping an array under a "data" key, or a single object (converted to one row). Array items must be objects.

How are nested objects handled?

Enable Flatten nested objects to convert nested keys to dot notation (user.name). Disable to keep nested values as JSON strings inside a single cell.

How does quoting work?

Fields are wrapped in double quotes only when they contain the delimiter, a quote, or a newline. Inner quotes are doubled per RFC 4180. Toggle wrap-all to force quoting everywhere.

Is the JSON to CSV Converter free to use?

Yes, the JSON to CSV Converter is 100% free with no registration, no hidden fees, and no usage limits. All processing happens locally in your browser, ensuring complete privacy.

Is my data safe with this tool?

Absolutely. The JSON to CSV Converter processes everything client-side in your browser. No data is uploaded to or stored on any server. Your content remains private on your device at all times.

Does the JSON to CSV Converter work on mobile devices?

Yes, the JSON to CSV Converter is fully responsive and works on smartphones and tablets. You can use it on any device with a modern web browser -- no app download required.

Do I need to create an account to use this tool?

No account or registration is needed. Simply open the JSON to CSV Converter in your browser and start using it immediately. There are no sign-up walls or usage restrictions.

How do I use the JSON to CSV Converter?

Simply enter your input in the provided field, adjust any settings to your preference, and the tool will process it instantly. You can then copy the result to your clipboard or download it.

Which browsers are supported?

The JSON to CSV Converter works in all modern browsers including Chrome, Firefox, Safari, Edge, and Opera. For the best experience, use the latest version of your preferred browser.

What happens when JSON objects have different keys?

The converter builds the column list from the union of every key found across all your objects, in first-seen order. So if the first record has "id" and "name" and a later one adds "email", the CSV gets all three columns and the records that lack "email" simply get an empty cell there. This means inconsistent API responses, where some items carry extra optional fields, still line up into a clean, rectangular table instead of misaligning. Values stay matched to their correct header regardless of the order keys appear inside each object, so a field placed last in one record still drops into the right column. The row and column counts shown above the output confirm the final shape before you export, and the live preview table lets you eyeball the alignment. Paste your mixed-shape JSON and the tool reconciles the columns automatically, giving every record the same header row with no manual cleanup.

How are arrays inside a JSON record converted to CSV?

A CSV cell holds a single value, so an array nested inside a record has no fixed column shape to spread across. Because of that, this tool always serialises an inner array back to a compact JSON string and places it in one cell — for example a "tags" field becomes ["a","b"] inside that column, even when flattening is enabled. This is intentional: flattening only expands nested objects into dot-notation columns like address.city, while arrays are kept intact as text so no data is lost. If you need each array element on its own row instead, restructure the JSON first so each element becomes its own object, then convert. The same applies to deeply nested structures: objects flatten into dot-notation columns while any array at any level stays as a JSON string. Paste your JSON and check the preview table to see exactly how array fields are rendered, then copy or download once the layout looks right.

Why should I use a semicolon or tab delimiter instead of a comma?

Comma is the default and the most widely supported separator, but it causes problems in some situations. In many European locales the comma is the decimal mark, so spreadsheets there expect a semicolon between fields — choosing semicolon makes the file open correctly in those regional Excel installs. The tab delimiter produces TSV, which pastes cleanly straight into a spreadsheet cell without a separate import step and avoids comma collisions entirely. Pipe is handy when your data itself contains commas and semicolons and you want a separator that almost never appears in real values. Whichever you pick, the tool still quotes any field that contains that delimiter, so the output stays valid and parseable. The chosen delimiter also shows on a badge beside the output so you always know what separates the columns. Pick the delimiter from the options above to match your target program or locale, then download the .csv.

Can I open the converted CSV directly in Excel or Google Sheets?

Yes. The output follows RFC 4180, the de facto CSV standard, so the downloaded converted.csv file opens in Excel, Google Sheets, Numbers, and database import tools without manual fixing. Fields containing a delimiter, quote, or line break are wrapped in double quotes and inner quotes are doubled, which is exactly what these programs expect when parsing. If commas in your numbers cause Excel to split columns in your locale, switch the delimiter to semicolon before exporting. For Google Sheets, you can also use File then Import, or simply copy the output and paste it into a sheet. Keep the header row toggle on so the first line becomes your column titles, or turn it off when you only need the raw data rows. The file is saved with a UTF-8 character set, so accented names and non-Latin text survive the round trip into your spreadsheet. Paste your JSON, confirm the preview table, then copy or download the spreadsheet-ready file.

What does the converter do if my JSON is invalid or empty?

Nothing breaks. If the text cannot be parsed, the tool shows an "Invalid JSON" message with the underlying reason rather than producing a corrupt file, so you can find the stray comma or unclosed bracket. If the JSON parses but an array item is a string, number, array, or null instead of an object, it stops and tells you the exact index that is invalid, since every item must be an object to become a row. An empty array produces a clear "nothing to convert" notice, and a single object is accepted but flagged as being treated as one row. These guards mean you always get either a correct CSV or a precise explanation, never a silently broken export that fails later. The messages appear inline right under the input as you type, so you can fix and re-paste without losing your place. Paste your data and let the notices guide you to a clean, valid result.

About the JSON to CSV Converter

The JSON to CSV Converter turns structured JSON into a flat, spreadsheet-ready CSV file. Paste a JSON array, an object that wraps an array, or even a single object, and the tool parses it instantly and shows the resulting CSV alongside a preview table. It is built for developers exporting API responses, analysts who need data in Excel or Google Sheets, and anyone who has a .json file but needs rows and columns instead.

Everything happens in your browser. The JSON you paste is parsed and converted on your own device using client-side JavaScript — nothing is uploaded to a server, so API dumps, customer records, and other sensitive data never leave your machine. There is no sign-up, no file-size account limit, and no software to install.

What input shapes it accepts

The converter normalises three common JSON structures into rows:

  • An array of objects[{"id":1},{"id":2}] becomes one row per object. This is the standard shape most APIs return.
  • An object wrapping an array{"data":[...]} is unwrapped automatically, since many APIs nest their results under a data key.
  • A single object{"a":1,"b":2} is converted to a single row, with a notice telling you it was treated as one record.

Every item in the array must itself be an object. If an entry is a string, number, array, or null, the tool stops and tells you exactly which index is invalid rather than producing a broken file. Columns are built from the union of all keys across your objects, in first-seen order, so records with different fields still line up correctly — missing values simply become empty cells.

Handling nested data and delimiters

Real JSON is rarely flat, so flattening is on by default. With Flatten nested objects enabled, a nested object like {"address":{"city":"NYC"}} becomes a column named address.city using dot notation. Turn flattening off and the whole nested value is kept as a JSON string inside one cell instead. Arrays inside a record are always serialised to a JSON string, since they have no fixed column shape.

You can also choose the delimiter that separates fields — comma, semicolon, tab, or pipe. Comma is the default and the most widely supported, but semicolon is handy for locales where the comma is a decimal separator, and tab produces TSV that pastes cleanly into spreadsheets.

Correct, spreadsheet-safe quoting

CSV breaks when a value contains the delimiter itself, a line break, or a quote character. The JSON to CSV Converter follows RFC 4180, the de facto CSV standard: a field is wrapped in double quotes only when it contains the delimiter, a quote, or a newline, and any quote inside a field is escaped by doubling it (" becomes ""). This keeps the output minimal and clean while staying parseable by Excel, Google Sheets, pandas, and database import tools. If you prefer maximum safety or a downstream parser that expects it, the Wrap all fields in quotes option forces quoting on every value. You can also toggle the header row off when you only want the data.

Why convert JSON to CSV

JSON is the language of APIs and JavaScript, but CSV is the language of spreadsheets and reporting. Converting between them lets you load API output into Excel for a quick pivot, hand a dataset to a non-technical colleague, seed a database import, or prepare data for a BI tool that does not read JSON.

To use it, paste your JSON (or click Sample to try a built-in example), adjust the options, and watch the output and preview update live. The preview table shows the first 10 rows with a running count of rows and columns, so you can confirm the structure before you act. When it looks right, copy the CSV to your clipboard or download it as a .csv file in one click.