CSV to JSON Converter Online
This free converter turns CSV (comma-separated values) data into JSON instantly. The first row is treated as the header, each subsequent row becomes a JSON object with those headers as keys, and numeric and boolean values are typed automatically instead of being left as strings.
It is ideal for turning spreadsheet exports into API fixtures, seeding databases, converting reports for JavaScript apps, or inspecting CSV files without opening a spreadsheet. Conversion runs entirely in your browser, so business data stays private.
How to use CSV to JSON
- Paste your CSV (including the header row) into the input box — the JSON appears automatically as an array of objects.
- Adjust the options if needed: pick a delimiter (auto-detect, comma, semicolon, tab, or pipe), toggle whether the first row is a header, and choose whether to parse numbers and booleans (off by default, so IDs and leading zeros stay intact).
- Use the swap button to reverse direction and convert a JSON array of objects back to CSV.
- Copy or download the result.
How the conversion maps rows to objects
Each header cell becomes a property name and each row becomes one object in the output array. Values that look like numbers or booleans are converted to real JSON numbers and booleans (dynamic typing), which is usually what APIs and test fixtures need.
name,age,active
Alice,30,true
Bob,25,false
→
[
{ "name": "Alice", "age": 30, "active": true },
{ "name": "Bob", "age": 25, "active": false }
]Related terminology
- CSV
- Comma-separated values — a plain-text table format where each line is a row and commas separate fields, exported by every spreadsheet tool.
- Header row
- The first CSV line naming each column; this converter uses it to produce JSON object keys.
- Dynamic typing
- Detecting that "30" is a number and "true" a boolean and emitting them unquoted in JSON rather than as quoted strings.
- Delimiter
- The character separating fields — a comma in CSV; quoted fields may contain delimiters and line breaks.
Frequently asked questions
- How do I convert a CSV file to JSON?
- Open the file in any text editor or spreadsheet, copy its contents (with the header row), and paste them into the input box. The JSON array appears instantly, ready to copy.
- Does the converter handle quoted fields and commas inside values?
- Yes — parsing follows standard CSV rules, so quoted fields containing commas, quotes, or line breaks are handled correctly.
- Why are my numbers unquoted in the JSON output?
- By default every value is kept as a string, so IDs, ZIP codes, and leading zeros are preserved. Turn on the "Parse numbers & booleans" option to convert numeric-looking values into JSON numbers and true/false into booleans.
- Is my data uploaded to a server?
- No. Parsing and conversion run entirely in your browser, making the tool safe for customer lists and internal reports.