Text tool
CSV and JSON
Convert between CSV and JSON without the usual damage. The parser handles quoted fields containing commas and line breaks, which is where the split-on-comma approach falls apart.
Why splitting on commas does not work
CSV looks trivial and is not. A field can be wrapped in double quotes, and a quoted field may contain the delimiter, a line break, and doubled quotes standing in for a literal quote character. This is a single valid row with three fields:
Ada,"London, England","She said ""hello"""
Split that on commas and you get five fields, two of them nonsense. Every spreadsheet in the world produces rows like it the moment a cell contains a comma, and every hand-rolled importer breaks on them.
The parser here walks the text character by character and tracks whether it is inside a quoted field, which is the only way to get this right. It also handles CRLF and LF line endings mixed in one file, and strips the byte order mark that Excel puts at the start of a UTF-8 export — without that, the first column name silently becomes something no lookup will ever match.
Detecting the delimiter
Comma is not universal. Much of Europe uses a semicolon, because the comma is the decimal separator there. Tab-separated exports are common out of databases. Pipe turns up in older systems.
Leave the delimiter on Detect and the first twenty lines are parsed with each candidate; whichever produces the most consistent number of columns wins. Override it if the guess is wrong — which happens on files where the first rows are a title block rather than data.
CSV to JSON
With first row is the header ticked, each row becomes an object keyed by the header names — the shape almost every API and script wants. Empty header cells become column_1, column_2 and so on, rather than an empty key that is impossible to address.
Untick it and you get an array of arrays: the raw grid, positions preserved.
Every value comes out as a string. That is deliberate. CSV has no types, and guessing produces the classic damage: a product code like 0012 becomes the number 12, a version like 1.10 becomes 1.1, and a long ID loses its last digits to floating point. Converting a column you know is numeric is one line of code at the far end; recovering a mangled identifier is not possible.
JSON to CSV
Give it an array of objects and you get a header row plus one row per object. The columns are the union of every key across every object, in the order first seen — not just the keys of the first object, which is the common shortcut and which silently drops fields that only appear later in the file.
Values that are themselves objects or arrays are written as JSON inside the cell, because CSV is flat and there is nowhere else for them to go. Anything containing the delimiter, a quote, a newline or leading whitespace is quoted and escaped properly on the way out.
Where this one earns its place
Spreadsheet exports are full of names, addresses, salaries and customer records. Pasting one into an online converter sends all of it to somebody's server, and most converters that do that are ad-supported by exactly the sort of people you would not choose.
This runs in your tab. There is no request and no endpoint that could receive the data. For a file too large to paste comfortably, the file picker reads it locally — the browser opens it directly and it still never leaves the machine.