Convert CSV to JSON
Transform CSV into JSON and JSON back into CSV entirely in your browser. Pick a delimiter, control header handling and typing, preview rows and columns, and read a conversion summary without uploading your data anywhere.
TL;DR
The CSV/JSON Converter runs entirely in your browser. Your data is parsed and transformed locally — there is no upload and no server-side processing. Switch between CSV to JSON and JSON to CSV directions, choose a delimiter, configure header handling, and read a row-and-column summary before you copy or download the result.
The tool handles both directions of conversion, auto-detects delimiters when you ask it to, and reports issues (such as ragged rows) as warnings rather than silently dropping data.
Why convert in the browser
CSV is the lingua franca of data export — spreadsheets, databases, and APIs all hand it out — but application code almost always wants JSON. Converting in your browser means sensitive rows (customer lists, financial exports, logs) never touch a third-party server. It also means instant feedback: change a delimiter or toggle a header and the output updates immediately, with a preview you can scan before committing.
Convert CSV to JSON
- Open the CSV/JSON Converter and select the CSV to JSON mode.
- Paste your CSV into the source area.
- Choose a Delimiter: Auto (the default, which detects the separator), Comma, Semicolon, Tab, or Pipe. Auto is useful when you are not sure whether an export is comma- or semicolon-delimited.
- Set the CSV options that shape the output:
- Header — treat the first row as field names so the JSON uses object keys instead of array indexes.
- Dynamic typing — convert numeric and boolean-looking values into real numbers and booleans instead of leaving them as strings.
- Skip empty lines — ignore blank rows rather than emitting empty records.
- Trim headers — strip whitespace from header names for cleaner object keys.
- JSON Lines — emit one JSON object per line (NDJSON) instead of a single JSON array.
- Minify — drop indentation to produce compact output.
- Click convert and read the summary (rows, columns, the detected delimiter, output size) and the preview.
When the header option is on, each row becomes an object keyed by the header names; when it is off, each row becomes an array of values. Ragged rows and other structural issues appear as warnings in the issues list rather than failing the whole conversion.
Convert JSON to CSV
- Switch to the JSON to CSV mode.
- Paste your JSON. The source should be an array of flat objects (or values the converter can flatten) — deeply nested or non-tabular shapes are reported as unsupported rather than silently coerced.
- Choose a Delimiter: Comma, Semicolon, Tab, or Pipe. Auto-detect is a CSV-input feature, so it is not offered when generating CSV.
- Set the JSON options:
- Header — write a header row from the object keys as the first line.
- Minify — produce compact CSV without extra spacing.
- Convert and review the summary and preview.
The converter collects the union of keys across the objects for the header and writes one row per object. Invalid JSON is caught and reported with a clear message rather than producing a half-written file.
Work with files
You can paste data directly or load a file. The tool validates the file before reading it: unsupported file types and oversized files are rejected up front with an explicit message (unsupportedFile or fileTooLarge), so you find out immediately rather than after a partial parse. When you are done, a download action produces a file named igottools-csv-json-converter.json (or .csv) for the current direction.
Read the summary and preview
Every successful conversion returns a summary and a preview alongside the output:
- Summary — total rows, total columns, the delimiter actually used, error count, and output size in bytes.
- Preview — the detected headers and a sample of the converted rows, so you can confirm structure before copying or downloading.
- Issues — when the conversion succeeds with caveats (for example, ragged rows or coerced values), they appear as a list of row-numbered warnings. A pure success has no issues; a hard failure returns an invalid result with a message key.
Honest limits and caveats
- Flat data works best. The converter is built for tabular data: arrays of flat records. Deeply nested JSON or non-uniform objects may be reported as an unsupported shape rather than flattened heuristically.
- Auto-detect is for CSV input only. When generating CSV you must pick a concrete delimiter; Auto is not available in that direction.
- File size is bounded. Oversized files are rejected before parsing. For very large datasets, split the input or use a dedicated offline pipeline.
- Dynamic typing is opt-in. By default values stay as strings so you can see exactly what was in the source. Turn on dynamic typing only when you trust the data to be consistently numeric or boolean.
- No persistence. The converter does not remember your input or output. Refresh the page and everything is cleared — the safe default for sensitive data.
Related tools
- JSON Formatter — pretty-print, validate, and explore the JSON you just produced. See
/en/tools/dev/json-formatter/. - JSONPath Tester — query the converted JSON with JSONPath expressions to pull out the rows you need. See
/en/tools/dev/jsonpath-tester/. - JSON to TypeScript — generate TypeScript types from the converted JSON for your application code. See
/en/tools/dev/json-to-typescript/.
FAQ
Is my data uploaded anywhere?
No. The conversion runs entirely in your browser. Your CSV, JSON, and any loaded file are parsed and transformed locally and never sent to a server.
Which delimiters can I use?
For CSV input: Auto, Comma, Semicolon, Tab, or Pipe. For JSON-to-CSV output: Comma, Semicolon, Tab, or Pipe (Auto-detect is not offered when you are generating CSV).
What does the Header option do?
In CSV to JSON it treats the first row as field names, so each record becomes an object keyed by those names instead of an array. In JSON to CSV it writes the object keys as the first row of the output.
What happens with ragged or malformed input?
Hard failures (empty input, invalid JSON, unsupported shapes) return a clear invalid result. Recoverable issues such as ragged rows produce a successful conversion with a list of row-numbered warnings, so you can see what was adjusted without losing the rest of the data.
Can I get JSON Lines (NDJSON) output?
Yes. In CSV to JSON mode, turn on JSON Lines to emit one JSON object per line instead of a single JSON array — handy for streaming parsers and log-style pipelines.

Start with this tool
Get started