Small tasks. A little easier.126 tools · No account required

Find your next tool

Search all 126 tools and their practical guides.

Developer

Export flat JSON to CSV with formula-aware handling

Create a properly quoted CSV from flat objects, preserve identifiers, and understand apostrophe prefixes on formula-like strings.

ERITHRA editorial3 min read

Flatten records before exporting

A CSV represents a rectangle of rows and columns. The JSON to CSV Converter therefore accepts a nonempty JSON array containing flat objects. Nested objects and arrays must be flattened before export. Decide whether an address should become separate city and postcode columns rather than relying on an accidental object-to-text conversion.

The converter collects the union of keys across all rows. A field missing from one row becomes an empty cell, as does a null value. This means the CSV cannot preserve the distinction between missing, null, and an empty text value without an additional convention that you define.

Check quoting with a small record

Enter this JSON and process it:

[{ "code": "0012", "name": "Bolt, brass", "quantity": 3 }]

The expected CSV is:

code,name,quantity
0012,"Bolt, brass",3

The comma-containing name is quoted so it remains one cell. The code’s digits remain in the exported text, but a spreadsheet may still infer a numeric type when opening the file. Import that column explicitly as text if retaining 0012 matters. CSV quoting controls separators; it does not reliably tell every spreadsheet to keep a value as text.

Recognize formula protection

Formula-like string values receive an apostrophe prefix. For example, the string =1+1 is exported with that prefix rather than being offered directly as a spreadsheet formula. The implementation enables Papa Parse’s escapeFormulae setting; Papa Parse documents the leading characters it handles, including =, +, -, and @.

This intentionally changes some cell text to reduce formula injection risk. It is not a substitute for reviewing untrusted data in the receiving spreadsheet. A round trip through CSV to JSON can retain the added apostrophe, so do not promise byte-for-byte reversibility when formula protection has acted.

Protect precision before parsing

Use strings for long identifiers in the original JSON. A numeric literal may already lose precision when the browser parses it; CSV export cannot recover digits that were rounded at that stage. JSON Formatter has the same underlying numeric limitation.

The tool accepts up to 5,000 rows and 250,000 input characters and downloads converted.csv. Processing stays in the browser. Review the resulting file’s headers, sample cells, and handling of sensitive records before passing it to another application or sharing it with colleagues.

JSONCSVspreadsheets

Put it into practice

Keep reading