CSV ↔ JSON Converter
Two-way converter with a live preview table. CSV → JSON parses RFC 4180-style with quoted fields, auto-detects the delimiter, and infers numbers, booleans and null. JSON → CSV flattens nested objects with dot notation and supports comma, semicolon, tab or pipe delimiters with LF or CRLF endings.
Your data is parsed locally in the browser. Nothing is uploaded.
How to use this csv ↔ json converter
- Paste CSV (or click Load sample) — the preview and JSON output update instantly.
- Choose a delimiter, or leave it on Auto-detect.
- Toggle 'first row is header', type inference, trim and pretty-print as needed.
- Switch the tab to JSON → CSV. Paste an array of objects.
- Toggle Flatten to turn nested keys into dot notation. Pick LF or CRLF and download.
Frequently asked questions
Does this handle quoted CSV fields with commas inside?
Yes. The parser follows RFC 4180-style quoting, including escaped double quotes ("").
What does 'flatten' do for JSON → CSV?
Nested keys like { profile: { age: 32 } } become a single column 'profile.age'. Arrays are joined with commas inside a quoted cell.
Why are numbers shown unquoted in JSON output?
Type inference converts numeric strings, true/false and null/NULL to their JSON types. Turn it off to keep everything as strings.
Why do leading zeros in my CSV (like '007' or phone numbers) get stripped in JSON output?
Type inference sees a numeric-looking string and converts it to a JSON number — and `007` is the same number as `7`. Turn off type inference to keep everything as strings, or rename the column header to something the inference skips. For ZIPs, IDs and phone numbers, strings are the right type anyway.