⇄

CSV to JSON Converter

Convert CSV data to a JSON array. Auto-detects delimiter, handles quoted fields, and downloads the result.

About this tool

Last updated:

Convert CSV to a JSON array

This CSV to JSON converter turns pasted CSV text into a JSON array of objects. Each row becomes one object, and the header names become the keys. You can copy the result or download it as a .json file.

How to use it

  1. Paste your CSV into the CSV Input box.
  2. Choose a Delimiter: Auto-detect, Comma, Semicolon or Tab.
  3. Choose Pretty or Minified output.
  4. Untick First row is a header if your data has no header row.
  5. Click Convert to JSON, then use Copy or Download .json.

How it works

The parser reads the whole text as CSV records. Quoted fields can contain the delimiter, line breaks and escaped quotes (""), and both LF and CRLF line endings work. A leading byte-order mark, which Excel adds to "CSV UTF-8" files, is removed. Blank lines are skipped.

With Auto-detect, the tool counts commas, semicolons and tabs in the first line (outside quotes) and uses the most frequent one.

What you see

  • A preview table of the first 5 rows.
  • The full JSON output in a read-only box.
  • Without a header row, keys are named column1, column2 and so on.
  • If a row is shorter than the header, the missing values become empty strings.

Assumptions and limits

  • Every value is output as a string. Numbers, true/false and empty cells are not converted to other JSON types.
  • Values in a row beyond the number of headers are ignored.
  • Duplicate header names overwrite each other, so keep headers unique.
  • Input is pasted text. There is no file upload.

Frequently asked questions

Why are my numbers wrapped in quotes?

The converter keeps every CSV value as text. If you need real numbers or booleans, convert those fields in your own code after parsing.

Can it read semicolon-separated files?

Yes. Auto-detect picks semicolons when they are the most common delimiter in the first line, or you can select Semicolon yourself. Tab-separated data works the same way.

What if my CSV has no header?

Untick "First row is a header". Every row is then treated as data and the keys become column1, column2, and so on.

More to explore

Related Developer Tools

Browse all tools from the same category.

Showing 1-2 of 49