CSV to JSON Converter
Convert CSV to JSON. Parses real CSV grammar — quoted fields with embedded commas, newlines and escaped double-quotes — with a comma, semicolon or tab delimiter, and outputs either an array of objects (first row as headers) or an array of arrays. Runs entirely in your browser.
Input
Options
On: array of objects keyed by the header row. Off: array of arrays.
Output
Guides
Turn CSV data into JSON in your browser — no upload, no spreadsheet software required. Paste rows copied from Excel, Google Sheets, or a database export, and get back a clean, structured JSON array you can drop into an API payload, a config file, or a test fixture.
How to use it
- Paste your CSV into the input box, or drop a
.csvfile onto the uploader. - Choose the delimiter — comma, semicolon or tab — to match your source data.
- Toggle First row contains headers to switch between an array of objects (headers become keys) and an array of arrays (every row, headers included, as a plain list).
- Pick an indent — 2 spaces, 4 spaces, tab, or minified — and copy or download the result as
converted.json.
The output updates automatically as you type.
How is quoting handled?
The parser follows the real CSV grammar (RFC 4180), not a naive comma split. A field wrapped in double quotes can safely contain the delimiter, a line break, or a literal double quote written as "" — for example "Smith, John" parses as one field containing a comma, and a quoted field can even span multiple lines. That means real-world exports from Excel or Google Sheets, which routinely quote fields for exactly this reason, convert correctly instead of silently splitting a value in two.
Array of objects vs. array of arrays — which should I use?
With First row contains headers on (the default), each row becomes an object keyed by the column names in the first row — the natural shape for feeding a JSON API or an array of records into your code. Turn it off and every row, including what would have been the header row, becomes a plain array of strings — useful for raw tabular data with no meaningful column names, or when you want to build the objects yourself.
What if a row has more or fewer fields than the header row?
A short row fills the missing trailing columns with empty strings; a long row's extra fields beyond the last header are dropped. This keeps ragged, hand-edited CSV exports from throwing an error — you get one JSON object per row either way.
Which delimiter should I pick?
Comma is standard and the default. Use semicolon for exports from locales where the comma is the decimal separator (much of Europe uses this convention in Excel), and tab for TSV data copied straight out of a spreadsheet.
Are the values typed as numbers or booleans?
No — every field converts to a JSON string, exactly as it appeared in the CSV ("30", not 30). CSV has no native type system, so guessing at numbers/booleans risks mangling values like phone numbers, ZIP codes or IDs that happen to look numeric. If you need typed values downstream, cast them there where you control the schema.
Is my data uploaded anywhere?
No. Parsing runs entirely in your browser using a self-contained CSV parser — your data, including anything sensitive in a customer or financial export, is never sent to a server, logged, or stored.
What's the inverse of this tool?
The JSON to CSV Converter does the reverse conversion, using the same delimiter options and RFC 4180 quoting, so a round trip through both tools is lossless.
Use it from code
From 3 credits per callREST API
curl -X POST https://api.iotools.cloud/v1/tool/csv-to-json-converter \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"csvSource": "name,age,city\nAlice,30,New York\nBob,25,Los Angel…",
"delimiter": ",",
"firstRowHeaders": "true",
"indent": "2"
}'Swap in your own key from your account. The tool's fields are the body — no wrapper.
Ask an AI agent
Use the IOTools `csv-to-json-converter` tool (CSV to JSON Converter) on this input:
YOUR_INPUT_HEREPaste this at any agent connected to the IOTools MCP server, then add your input.