Choose your workflow

Choose a JSON export format

The best JSON export format is the one your receiving system can read without guessing. A spreadsheet wants rows and columns, a configuration file wants predictable keys, an integration may need XML, and a log pipeline usually wants one record per line.

Choose the output format for the system that will read it. JSON All-in-One exports locally from the source document or a shaped result; the sections below explain the mapping decisions and link to a focused guide for each format.

Start with the destination

Ask where the output will go first. If the next stop is Excel, Sheets, a BI import, or a database loader, use CSV or TSV and review column types during import. If the next stop is a README, issue, or report, a Markdown table or HTML table is easier to read. If the output becomes configuration, YAML, TOML, or .properties may fit better, but only after you check that the receiving application expects that structure.

JSON can nest objects, arrays, strings, numbers, booleans, and nulls in one tree. Most export formats cannot preserve that entire model without choices. The useful question is not whether a format is universally lossless. The useful question is whether the mapped output matches the job you are handing off.

Procurement handoff workflow comparing the same 360 awards as a documentation table, nested configuration-style data, and a line-delimited integration stream, with each generated artifact checked against its receiver contract.

Export format comparison

FormatBest forWatch forGuide
CSVComma-delimited spreadsheet and database handoffsNested paths, missing cells, spreadsheet type coercion, formula-like prefixesNested JSON to CSV
TSVTab-delimited spreadsheet imports where commas are common in valuesTabs/newlines inside cells, identifier columns, formula-like prefixesJSON to TSV
YAMLReadable configuration or reviewable nested dataYAML version differences, quoted scalars, no recovery of comments or anchorsJSON to YAML
TOMLConfiguration that expects tables and arrays of tablesNo null value; mixed arrays are valid TOML 1.0 but restricted by this exporterJSON to TOML
.propertiesFlat key/value configurationDots, array indexes, escaping, and application-specific bindingJSON to .properties
XMLHierarchical interchange with XML consumersRoot element, element names, repeated values, and schema expectationsJSON to XML
Markdown tableREADME, issue, and documentation tablesWide rows, pipe escaping, and multiline readabilityJSON to Markdown table
HTML tableShareable table reports opened in a browserSaved artifact behavior, escaping, sorting, and mapping differences from CSVJSON to HTML table
NDJSON / JSONLLine-oriented pipelines and record-by-record processingEvery line must be an independently parseable JSON valueJSON array to NDJSON

One input can have several useful outputs

The same source can be exported in different ways depending on what you need next. When the useful rows are wrapped inside a root object, make the selection explicit first. For a table export, the nested fields become columns such as customer.plan. For NDJSON, the shaped array becomes separate records.

Source JSON with root wrapperjson
{
  "orders": [
    {"order_id":"A-1001","customer":{"name":"Mina Lee","plan":"pro"},"amount":"0012.50","status":"paid"},
    {"order_id":"A-1002","customer":{"name":"Noah Park","plan":"free"},"amount":"-12","status":null}
  ]
}
JQ query for row exportsjq
.orders
Shaped array to exportjson
[
  {"order_id":"A-1001","customer":{"name":"Mina Lee","plan":"pro"},"amount":"0012.50","status":"paid"},
  {"order_id":"A-1002","customer":{"name":"Noah Park","plan":"free"},"amount":"-12","status":null}
]
CSV-shaped outputcsv
order_id,customer.name,customer.plan,amount,status
A-1001,Mina Lee,pro,0012.50,paid
A-1002,Noah Park,free,"'-12",null
NDJSON outputndjson
{"order_id":"A-1001","customer":{"name":"Mina Lee","plan":"pro"},"amount":"0012.50","status":"paid"}
{"order_id":"A-1002","customer":{"name":"Noah Park","plan":"free"},"amount":"-12","status":null}
Procurement JSON routed to spreadsheet, documentation, configuration, and event-stream receivers based on row shape, nesting, and record-boundary requirements.
Receiver-first decision map separating spreadsheet rows, documentation tables, nested configuration, and event streams by the contract each destination expects.

Export the source or a shaped result

Before exporting, decide whether you want the whole document or a smaller result. A JQ query can project only the fields you need, filter records, rename columns, or build an array that is easier to hand off. That is usually better than exporting a huge source and cleaning it later.

For row-based exports, start from an array when possible. CSV, TSV, Markdown table, HTML table, and NDJSON all depend on a row or record model. If your source is a nested object with the records buried inside, shape the desired array first with a query, then export that result.

Common export pitfalls

  • CSV and TSV are text formats. Spreadsheet applications may still convert values such as long IDs, dates, or negative-looking strings unless you choose deliberate import types.
  • Formula-like CSV/TSV cells can be apostrophe-prefixed for safety. That includes cells beginning with =, +, -, @, a tab, or a newline, so check negative numeric text before claiming exact spreadsheet handoff.
  • TOML has no null value. Mixed-type arrays are allowed by TOML 1.0, but the current exporter requires matching array value types; the TOML guide explains that separate limitation.
  • Markdown table output is for tables, not arbitrary prose generation. Use HTML or CSV when rows are wide or multiline content must remain easier to inspect.
  • HTML table export creates a report artifact, not a general web application. Verify the saved file, not only the workspace preview.
  • NDJSON and JSONL require one complete JSON value per nonempty line. Source formatting line breaks are not record boundaries.

Export guides

Choose the detailed workflow that matches your receiving system. Each guide includes a copyable input and target output, plus the caveats that matter for that format.