Nested JSON to Flat Table

Flatten nested JSON, expand one list into rows and download CSV or XLSX.

On-device No sign-up Free to use

Flatten JSON controls

Drop your file here

or choose one from your device

One UTF-8 .json file up to 8 MB holding a JSON object or array. A chosen file is used instead of the pasted text.

    ?

    Paste the JSON document, or leave this empty and choose a file. The document is read in your browser.

    ?

    For example data.items or data[0].rows. Leave empty and a top-level array is used; a single object whose only array property holds the records uses that array, and any other object is read as one record.

    ?

    One column per position is the default. JSON text and the joined form keep a long list inside a single cell. One row per entry repeats the other fields for every list entry, and only the first list in a record is expanded.

    ?

    A value or heading whose first visible character is = + - or @ receives an apostrophe in the CSV download, so a spreadsheet reads it as text. The prefix changes the stored value. A workbook stores every cell as inline text, so it is not prefixed.

    ?

    A workbook stores every cell as inline text, which a spreadsheet does not run, so the CSV formula guard is not applied and each value is stored exactly as it was.

    Result

    Showing an example.

    Flatten two orders with a nested address and a list of tags.

    The page reports two records in six columns: id, name, address.city, address.zip, tags.0 and tags.1. The download holds those headings, then 1,Ana,Bristol,BS1,a,b and 2,Lee,Leeds,,,

    Loading the tool. Your result will appear here.

    https://usefreetools.net/nested-json-flat-table · 20 November 2026

    Was this helpful?

    How to use Nested JSON to Flat Table

    1. Paste the JSON document or choose one UTF-8 JSON file.
    2. Point to the record array, such as data.items. With no path, the tool uses a top-level array, a single array property where applicable, or one object as a record.
    3. Choose dotted or bracketed column names and how lists are represented: indexed columns, JSON text, bar-joined values or one row per entry of the first list.
    4. Choose CSV or XLSX, flatten the document and review column collisions, renamed property names and expanded row counts before downloading.

    Example: Nested JSON to Flat Table

    Flatten two orders with a nested address and a list of tags.

    You add
    JSON: {"data":{"items":[{"id":1,"name":"Ana","address":{"city":"Bristol","zip":"BS1"},"tags":["a","b"]},{"id":2,"name":"Lee","address":{"city":"Leeds"},"tags":[]}]}}. Record path: data.items. Column names: Dotted paths. Lists: One column per list position. Formula protection: on.
    You get
    The page reports two records in six columns: id, name, address.city, address.zip, tags.0 and tags.1. The download holds those headings, then 1,Ana,Bristol,BS1,a,b and 2,Lee,Leeds,,,

    Options

    JSON text
    Paste the JSON document, or leave this empty and choose a file. The document is read in your browser.
    Path to the array of records
    For example data.items or data[0].rows. Leave empty and a top-level array is used; a single object whose only array property holds the records uses that array, and any other object is read as one record.
    How a list inside a record is handled
    One column per position is the default. JSON text and the joined form keep a long list inside a single cell. One row per entry repeats the other fields for every list entry, and only the first list in a record is expanded.
    Protect spreadsheet formulas in the download
    The JSON flattening CSV export can prefix formula-like source text, including after leading whitespace. This changes stored text. An XLSX export, when offered, uses inert text cells without the CSV prefix.
    Download format
    A workbook stores every cell as inline text, which a spreadsheet does not run, so the CSV formula guard is not applied and each value is stored exactly as it was.

    Supported inputs and limits

    • Up to 8 MiB of UTF-8 JSON, 50,000 source records, 100,000 expanded rows, 500 columns, 2,000,000 cells, depth 32 and 20,000 characters per cell.
    • A file replaces pasted text.
    • Row expansion affects only the first list in each record; other lists remain JSON text in that mode.
    • Column-name collisions receive suffixes and unsafe property names are renamed.
    • JSON numbers follow JavaScript precision, so quote long identifiers before flattening.
    More details

    CSV protection can prefix risky values;

    XLSX stores cells as inert text.

    Where your input is processed

    This tool does not upload your inputs. See the limits for anything saved on your device.

    Why a flattened column order is stable

    Columns are added in the order the records are met, and a record that arrives later can only add a new column at the end. Two runs over the same document therefore produce the same headings, which matters when the CSV feeds a script or a spreadsheet import.

    Questions about Nested JSON to Flat Table

    Which array does the page flatten when I leave the path empty?

    A top-level array is used as it is. An object whose only array property holds the records uses that property, and anything else is treated as one record, which is why the source line in the report names what it chose.

    Why is a column called a.b#2?

    Two different places can flatten to the same readable name, such as a key that itself contains a dot and a nested object below it. The later one takes a number suffix so both values survive, and the report names the paths involved.

    What happens to a list of objects?

    With one column per position, each entry is flattened into its own set of column names. The JSON text and bar-joined settings instead keep the whole list inside a single cell, which suits a long or irregular list.

    Is the document sent anywhere?

    It is not. The text is parsed in this page, the table is built from the parsed values, and the CSV download is created on your device.

    Does JSON flattening change formula-like text in Excel output?

    The JSON flattening XLSX download stores each value as inert text, preserving a leading equals or minus sign. CSV formula protection can instead add a prefix. Neither format recalculates saved workbook formulas.

    Page updated · Project managed by Tony Hines · Report a problem with Nested JSON to Flat Table