CSV to JSON
Convert CSV data to JSON instantly with support for headers, custom delimiters, and pretty print.
CSV Input
JSON Output
Changes update instantly
Examples
Input
name,age,city Alice,30,New York Bob,25,London
Output
[{"name":"Alice","age":"30","city":"New York"},{"name":"Bob","age":"25","city":"London"}]Input
id;product;price 1;Widget;9.99 2;Gadget;24.99
Output
[{"id":"1","product":"Widget","price":"9.99"},{"id":"2","product":"Gadget","price":"24.99"}]About this tool
Use this CSV to JSON converter to transform spreadsheet or export data into JSON format directly in your browser. It supports comma, semicolon, and tab-delimited files with automatic delimiter detection, an optional header row, and pretty-printed or compact output.
How to use
- Paste your CSV data into the input panel.
- The delimiter is detected automatically, or you can select one manually.
- Toggle whether the first row is a header and whether to pretty-print the output.
- Copy the JSON result from the output panel.
When to convert CSV to JSON
CSV is a common export format from spreadsheets, databases, and analytics tools. JSON is the standard format for APIs, web apps, and developer workflows. Converting between them is a frequent task when working with data exports or preparing data for code.
This tool handles the conversion in your browser without uploading your data anywhere, which is useful when working with sensitive or proprietary data.
Headers, delimiters, and output format
If your CSV has a header row, each JSON object will use those headers as keys. Without headers, the output is an array of arrays. The tool auto-detects whether the delimiter is a comma, semicolon, or tab, but you can also set it manually.
FAQ
Does this handle quoted fields with commas inside?
Yes. The parser follows standard CSV quoting rules, so fields enclosed in double quotes can contain commas, newlines, and escaped quotes.
What if my CSV uses semicolons instead of commas?
Select Semicolon as the delimiter, or leave it on Auto and the tool will detect it from the first row.
Can I convert CSV without a header row?
Yes. Toggle off the first-row-as-header option and each row will be output as a JSON array instead of a named object.
Related Tools
JSON Formatter
Format and validate JSON instantly.
Open tool
Duplicate Line Remover
Remove duplicate lines from text.
Open tool
Line Sorter
Sort text lines alphabetically instantly.
Open tool
Base64 Encoder & Decoder
Encode or decode Base64 strings instantly.
Open tool
Remove Extra Spaces
Remove extra spaces from text instantly.
Open tool
Markdown Previewer
Preview markdown and render it instantly.
Open tool