CSV to JSON

Convert CSV to JSON and back, with correct handling of quoted fields and embedded commas.

Paste CSV data to convert it.


Result will appear here.

Features

  • Both directions, CSV to JSON and JSON to CSV
  • RFC 4180 quoted fields with embedded commas and newlines
  • Four delimiter options including tab-separated
  • Optional automatic type detection
  • Headerless mode produces arrays instead of objects

How to use it

  1. Pick a direction and paste your data.
  2. Confirm the delimiter and whether row one is a header.
  3. Press Convert.
  4. Copy the result or download it as a file.

Why CSV parsing is trickier than splitting on commas

The naive approach, splitting each line on commas, breaks on the first field that contains one. RFC 4180 allows any field to be wrapped in double quotes, and a quoted field may contain commas, line breaks and even quotes, provided each embedded quote is doubled. So "Wilmslow, Cheshire" is one field, and "She said ""hi""" is the single value She said "hi".

That last rule means you cannot process CSV line by line either. A quoted field containing a newline spans multiple physical lines while remaining one logical record. This parser walks the input character by character tracking whether it is inside quotes, which handles all of these cases correctly.

Type detection is convenient but occasionally destructive, which is why it is a toggle. Turning it on converts 42 to a number and true to a boolean, usually what you want. But it also converts a US zip code like 02134 to the number 2134, losing the leading zero, and can mangle long identifiers that exceed JavaScript's safe integer range. Turn it off when your columns contain codes rather than quantities.

Frequently asked questions

Yes, completely. CSV to JSON is free with no usage limits, no account and no sign-up. There is no paid tier and no trial that expires. Tools marked Premium on this site carry that label to indicate a deeper feature set, not a price.
CSV to JSON covers both directions, CSV to JSON and JSON to CSV, rFC 4180 quoted fields with embedded commas and newlines, four delimiter options including tab-separated, among other things. Everything is available immediately with no account, no sign-up and no usage limit.
The naive approach, splitting each line on commas, breaks on the first field that contains one. RFC 4180 allows any field to be wrapped in double quotes, and a quoted field may contain commas, line breaks and even quotes, provided each embedded quote is doubled. So "Wilmslow, Cheshire" is one field, and "She said ""hi""" is the single value She said "hi".
Everything happens inside your browser. The text you enter is processed by JavaScript running on your own device and is never sent to a server, there is no backend to send it to. You can confirm this in your browser's Network tab while you use the tool. Because nothing depends on a server, the tool also keeps working offline once the page has loaded, the site registers a service worker that caches it after your first visit.

Related tools

Further reading

πŸ“– How to Convert CSV to JSON (and Why the Structure Changes)

Read the full guide on the 123MiniApps blog.

Pick a theme

Ten hand-tuned palettes.