CSV to JSON Converter
Paste CSV data and get a clean JSON array instantly. The first row is used as keys. Handles quoted fields and commas inside values. Runs entirely in your browser.
CONVERT
Comma-separated input. First row is used as object keys. Quoted fields with commas are handled correctly.
How it works
A character-by-character parser reads the CSV. A double quote at the start of a field opens a quoted section, where commas and line breaks are kept as part of the value and a doubled quote stands for one literal quote. CR, LF, and CRLF all end a row, a leading byte order mark is dropped, and fully empty lines are skipped. The first row supplies the keys, and JSON.stringify writes the array with two-space indentation.
Example
A quoted field keeps its comma, a doubled quote inside it becomes one quote, and every value comes out as a string:
name,note,age
"Smith, Jane","Said ""hi""",30[
{
"name": "Smith, Jane",
"note": "Said \"hi\"",
"age": "30"
}
]Processing runs in your browser
All conversion happens inside your browser tab using JavaScript. Our servers are not involved at any point.
Technical specification
CSV quoting follows the conventions in RFC 4180 (IETF, 2005): a field that contains a comma, a double quote, or a line break is wrapped in double quotes, and a double quote inside it is written twice.
- Standard
- RFC 4180. Common Format and MIME Type for Comma-Separated Values (CSV) Files
- Delimiter
- Comma only
- Output
- JSON array of objects, or CSV with LF line endings
- Download
converted.jsonorconverted.csv
Related operations
After converting, pretty-print or minify the JSON output. If your data starts as YAML, turn it into JSON first. To drop repeated lines from an export before converting, remove duplicate lines; the first occurrence of each line is kept, so the header row stays on top, and matching ignores letter case, so rows that differ only in case count as duplicates.
Frequently asked questions
- Does it handle quoted fields?
- Yes. Fields wrapped in double quotes are parsed correctly, including commas and newlines inside quotes.
- Is my CSV data uploaded?
- All parsing happens in JavaScript inside your browser tab. Our servers are not involved at any point.
- What if my CSV has no header row?
- The first row is always used as keys. If your CSV has no header, add one manually before pasting.
- What format is the JSON output?
- An array of objects, one per data row. Each object's keys come from the header row.
Last reviewed September 30, 2026
Other pages for this tool
Related tools
- Background reading: Complete guide to data tools
- Step by step: Turn a CSV into clean JSON for an API