The ToolMint JSON to CSV Converter converts JSON arrays or single JSON objects into CSV directly in your browser. Paste JSON, upload a .json file, validate the structure, choose columns, flatten nested objects when useful, preview rows and download a CSV file without sending JSON contents to ToolMint servers.
JSON to CSV conversion is useful when API data, application exports or static data files need to be opened in a spreadsheet, reviewed by non-developers, imported into another system or shared as a tabular report. JSON can represent nested data, arrays and typed values. CSV is flatter and easier to scan in spreadsheet software, but it needs clear columns and consistent row values.
What JSON to CSV conversion does
JSON stores structured values such as objects, arrays, strings, numbers, booleans and nulls. CSV stores rows and columns as text. A JSON to CSV converter reads JSON records, detects the available object keys, converts those keys into column headers and writes one CSV row for each record.
The cleanest input is an array of objects. For example, two objects with name, email and active properties become two CSV rows with those three columns. ToolMint also supports a single top-level object by converting it into one CSV row. Top-level primitive values such as "hello" or 42 are rejected because they do not contain records or columns.
How to convert JSON to CSV
Start by pasting JSON into the input area or uploading one .json file. Choose Validate JSON to parse the input, detect records and build the column list. If validation succeeds, ToolMint shows record count, detected column count, selected column count, delimiter and flattening mode.
Use the column selector to include, exclude or reorder fields before conversion. Choose a delimiter, decide whether to include a header row and choose whether nested objects should be flattened. When the preview looks right, select Convert to CSV. The output can be copied or downloaded as converted-data.csv.
Which JSON structures work best
The best shape is an array of similar objects:
[
{ "name": "Ava", "email": "ava@example.com" },
{ "name": "Omar", "phone": "123" }
]
ToolMint detects the union of all keys, so the columns become name, email and phone. Missing values are exported as empty CSV cells. This is safer than relying only on the first record, because later objects may contain fields that do not appear at the start of the file.
Empty arrays, arrays containing only primitives, mixed arrays of objects and primitives, and deeply irregular records are rejected or warned about. CSV needs a table-like structure; when the input cannot be represented without hiding data, the tool asks you to fix the JSON first.
How columns are detected
Column detection walks through every object record and preserves key order where practical. Keys from earlier records appear first, and new keys discovered in later records are appended. This makes the output predictable while still representing properties that are missing from the first row.
At least one column must remain selected before conversion. You can select all columns, clear all columns, toggle individual fields and move selected columns up or down. Column names are visible only in the browser UI and are not sent through analytics.
How nested objects are flattened
Nested objects are enabled by default because CSV is flat. ToolMint uses dot notation for nested properties. A value such as user.location.city becomes one CSV column when the JSON contains:
{
"user": {
"location": {
"city": "Dubai"
}
}
}
Flattening is limited to 10 levels to avoid pathological input. If JSON is deeper than that, the nested value is kept as JSON text and the tool shows a warning. If flattening is disabled, nested objects remain JSON-stringified cell values in their top-level columns.
How arrays and null values are handled
CSV output is text. Strings remain strings, numbers become plain text numbers, booleans become true or false, and null becomes an empty cell by default.
Arrays are not expanded into repeated rows because that can create ambiguous output. Primitive arrays and arrays of objects are serialized as JSON strings inside the relevant cell. This keeps the original value visible without inventing extra rows or silently dropping nested data.
Choosing a CSV delimiter
Comma is the default delimiter because it is the most common CSV format. Semicolon, tab and pipe are also available for regional spreadsheet exports, database imports and systems that reserve commas inside values.
ToolMint uses Papa Parse to serialize CSV, so delimiters, quotes, selected delimiters inside values, escaped quotes, multiline text and Unicode are handled by a CSV serializer rather than naive string joining. Header rows can be included for spreadsheet readability or excluded when another system expects raw rows only.
Common conversion mistakes
One mistake is assuming every JSON file is table-shaped. A single object can become one row, but a top-level primitive or mixed array does not provide a safe row-and-column model.
Another mistake is flattening without checking column names. Flattened dot notation is useful, but deeply nested APIs can produce many columns. Review the column selector and preview table before download.
A third mistake is expecting arrays to become multiple rows automatically. That decision depends on business meaning. ToolMint keeps arrays as JSON strings so the output remains predictable and does not duplicate records unexpectedly.
Privacy and local processing
The converter runs locally in the browser. JSON text is parsed in the current tab, files are read with browser file APIs and CSV is generated with client-side JavaScript. ToolMint does not upload JSON files or pasted JSON to its servers.
Analytics for this tool are limited to privacy-safe interactions such as validate, convert, copy, download, reset, delimiter mode and file-size bucket. Analytics do not include filenames, JSON contents, object keys, column names, cell values, record contents or generated CSV. Resetting the tool clears the page state; refreshing or closing the tab removes the in-memory data from the page.
Limitations
This browser tool is designed for JSON files around 20 MB or smaller. That is practical guidance, not a universal browser limit. Large datasets can be memory-heavy because the browser may hold the original JSON text, parsed records and generated CSV at the same time.
The converter does not execute code, infer dates, apply locale-specific number formatting, expand arrays into extra rows or convert binary spreadsheet files. If you need to inspect the source JSON first, use the JSON Formatter. To reverse the workflow, use the CSV to JSON Converter. For related text and encoding workflows, use the Text Diff Checker, Base64 Encoder / Decoder, URL Encoder / Decoder or Hash Generator. You can also browse more developer utilities in the Developer category.
Related ToolMint tools
Use the CSV to JSON Converter when you need to turn CSV back into JSON objects. Use the JSON Formatter to validate and inspect JSON before conversion. Use the Text Diff Checker to compare CSV or JSON versions. Use the Base64 Encoder / Decoder, URL Encoder / Decoder and Hash Generator for adjacent developer workflows.
The FAQ section below is generated from the ToolMint registry so visible answers and FAQ structured data stay synchronized.