CSV to JSON
Convert CSV (with quoted fields, embedded commas and line breaks) to a JSON array of objects. Optional auto-conversion of numbers and booleans. One-click copy or download.
Parser details
A full RFC 4180 state machine is used: fields may be quoted, quotes escape as "", and delimiters or line breaks inside quotes are preserved. Rows with more cells than the header are kept (extra values dropped is not what happens — extra columns are reported in the meta line), rows with fewer cells get null for the missing values. “Auto-convert” turns 42, 3.14, true, false and null into native JSON values; keep it off to force strings everywhere.
How to use CSV to JSON
Paste CSV output from Excel, a database or any export, and the JSON array appears on the right in real time. The first row becomes object keys, values are type-guessed automatically (numbers stay numbers), and delimiters like semicolons or tabs are detected — including the quirks of European locale exports.
Quoted fields with embedded commas, quotes or line breaks follow RFC 4180, so messy real-world exports parse correctly rather than collapsing into one broken row. The result drops straight into scripts, API payloads or database imports as typed JSON.
Frequently asked questions
How are commas inside cells handled?
Quoted cells that contain commas, quotes or line breaks are parsed per RFC 4180. A quote inside a quoted field is unescaped from two double-quote characters, so real-world exports parse correctly.
Does the header row become object keys?
Yes. The first row is treated as the header and each following row becomes an object. Empty header cells fall back to column indices, and the type guess keeps values like 42 numeric.
Can I convert JSON back to CSV?
Yes — open the JSON to CSV tool. It flattens nested objects with dot notation and quotes cells that contain separators, producing import-ready CSV for spreadsheets.
What happens with semicolon separated files?
Auto-detection checks delimiter frequency and switches to semicolon, tab or pipe input, which is common when Excel exports in European locales.