Convert CSV data to JSON format.
CSV to JSON Converter turns spreadsheet data into structured JSON, ready to use in an API, database, or application. Paste your CSV, choose the delimiter if needed, and get clean JSON output instantly.
Made for everyone. Typical uses:
The sample CSV with the header name,age,zip,active and the rows Ada,36,02134,true and "Sam, Jr.",41,90210,false gives two objects. The ages become numbers 36 and 41, active becomes true and false, and the zip values stay as the text "02134" and "90210".
Flat CSV produces flat JSON: a header such as address.city becomes a key with that name and is not rebuilt into a nested object. Dates stay as text, empty cells become empty strings instead of null, duplicate column names overwrite each other, and cells beyond the last header are ignored.
Accuracy: Conversions use well-known methods and are tested with real sample inputs. Check the output before you send or publish it.
Expert Tip
Switch off "Convert numbers, true/false and null" when you want every value kept exactly as written, for example before importing codes that must stay as strings.
The CSV to JSON Converter reads comma-separated text, with the first row as column names, and produces a JSON array with one object per data row. You paste the CSV or open a .csv or .tsv file, choose the delimiter, and press Convert to JSON. The output heading tells you how many rows were converted, and you can copy the result or download it as data.json. The conversion happens in your browser, so the data is not uploaded.
The Try an example button loads a header row of name, age, zip and active, followed by Ada, 36, 02134, true and then "Sam, Jr.", 41, 90210, false. The result is an array of two objects.
The "Convert numbers, true/false and null" option works column by column. A column is converted only when every non-empty value in it has the same type. If it is all numbers, they become numbers. If it is all true and false, they become booleans. If any value is different, such as a ZIP code with a leading zero, the whole column stays as text, so a column never ends up holding a mix of strings and numbers. Empty cells become empty strings, not null. Numbers with 16 or more characters stay as text to avoid rounding. Untick the option and every value is kept exactly as written.
The first row becomes the keys of every object. A blank header cell is named column1, column2 and so on by position. If two columns share a name, the later one overwrites the earlier one, so rename duplicates before converting. The delimiter can be a comma, semicolon, tab or pipe, which covers most exports from spreadsheets and databases. Quoted fields may contain delimiters, doubled quotation marks and even line breaks, and a byte-order mark at the start of a file is removed. A row with fewer cells than headers gets empty strings, and cells beyond the last header are ignored.
The tool needs a header row and at least one data row, and it says so when there is only one line. If a quoted field never closes, it reports that, which usually means a stray quotation mark. After conversion, the output goes straight into the JSON Formatter if you want a different indent or compact output, or into the JSON Validator if you want to double-check it.
Flat CSV produces flat JSON. A column called address.city becomes a key named "address.city" and is not rebuilt into a nested object. Dates stay as text, because JSON has no date type. If your target system expects a particular structure, reshape the output afterwards. To go back to a spreadsheet, use the JSON to CSV Converter, and if the JSON you produce is rejected by an API, the guide to common JSON errors explains the usual causes.
Explore more in Converters, read the guides and articles, or see how we test our tools.
Convert JSON data to CSV format.
Best for turning an API response into a spreadsheet for analysis
Format, beautify, and validate JSON data with proper indentation.
Best for formatting minified JSON from APIs for readability
Validate JSON syntax and check for errors.
Best for validating JSON before API deployment
Convert XML data to JSON format instantly.
Best for converting a legacy XML API response into JSON for a modern frontend