JSON to CSV
Paste a JSON array of objects and get CSV back, with the columns taken from the keys. Pick comma, semicolon or tab for the separator.
It handles one level of nesting by making dotted columns like address.city. Anything deeper, or an array, is written as its JSON text in a single cell, which the tool says plainly rather than dropping it.
An array of objects. One level of nesting becomes dotted columns like address.city; deeper structures and arrays are written as JSON text in a cell.
Paste a JSON array of objects to convert.
Questions
- Is what I paste sent anywhere?
- No. Every tool in this kit runs in the page itself. There is no server here that receives what you paste, and you can check it in your browser's network tab: using a tool produces no request carrying your input at all.
- What shape of JSON does it take?
- An array of objects, which is the usual shape of exported records. A single object is treated as one row. An array of plain values or of arrays is not a table, and the tool says so rather than guessing.
- How does it handle nested data?
- One level deep becomes dotted columns: an address object turns into address.city and address.zip. Anything deeper than that, and any array, is written as its JSON text in one cell, because forcing it into columns would either lose data or invent structure.
- What about commas inside a value?
- They are handled. A value containing the separator, a quote or a line break is wrapped in quotes with its own quotes doubled, which is the standard CSV escaping, so the row never splits in the wrong place.
- Which separator should I use?
- Comma for a .csv that opens anywhere. Semicolon if your spreadsheet is set to a locale that uses the comma as a decimal point. Tab for a .tsv, which avoids the comma question entirely.
The other tools here
- JSON formatter, format, minify and validate
- Base64 encoder, encode and decode, text or file
- URL encoder, encode and decode, two rules
- UUID generator, version 4, one to a hundred
- Hash generator, sha-256, sha-1 and md5 at once
- JWT decoder, header, payload and expiry
- Regex tester, live matches, groups and flags
- Text diff, compare two blocks, by line or word
- Timestamp converter, unix time to a date, and back
- Cron explainer, a schedule, in plain english
- Colour converter, hex, rgb, hsl, and a contrast check
- Markdown preview, live preview, and copy the html