What is JSON?
JSON (JavaScript Object Notation) is a text format for structured data built from objects, arrays, strings, numbers, booleans and null. It is defined by RFC 8259 and ECMA-404, is language-independent, and is the default format of web APIs because it is compact, human-readable and easy to parse.
How to use Nested JSON Generator
- Set depth, keys per object and items per array.
- Choose the leaf types and key style.
- Press Generate; explore the tree or download the JSON.
Nested JSON Generator features
- Depth up to 64 levels, up to 50 keys per object and 100 items per array
- Arrays mixed into the structure or objects only
- Leaf types: string, number, boolean, null, date, uuid
- Realistic, short or very long key names
- Tree view and JSON output with node count, depth and size
- 200,000-node safety limit with clear messages
Nested JSON Generator example
Small nested document
Input:
Depth: 3 · Keys: 2 · Arrays: off · Leaf types: number · Key names: Short (k0, k1…)Output:
{
"k0": { "k0": { "k0": 42, "k1": -7 }, "k1": { "k0": 3.14, "k1": 0 } },
"k1": { "k0": { "k0": 9, "k1": 12 }, "k1": { "k0": -1, "k1": 5 } }
}Frequently asked questions about Nested JSON Generator
What can I control?
Depth, keys per object, items per array, whether arrays are mixed in, leaf value types (string, number, boolean, null, date, uuid) and the key naming style.
Is there a size limit?
Yes — 200,000 nodes. Combinations that would explode (for example depth 30 × breadth 20) are rejected up front with a clear message.
What is it useful for?
Stress-testing parsers, recursion limits, schema validators, tree viewers, diff tools and serialisers with deeply nested documents.
Do all branches reach the requested depth, and is the root always an object?
Yes, as long as Items per array is at least 1. The root is always an object and every branch then descends to exactly the chosen depth, so the document is a full tree and the reported max depth equals your setting unless the 200,000-node cap cuts it short. Below the root, about 30% of containers become arrays when mixing is on; with Items per array set to 0 those arrays are empty and end their branches early, so the max depth can be lower than your setting.
References
- RFC 8259: The JavaScript Object Notation (JSON) Data Interchange FormatThe JSON grammar: objects, arrays, strings, numbers, the three literals, and UTF-8 as the interchange encoding.
- ECMA-404: The JSON Data Interchange SyntaxThe JSON syntax as an Ecma standard, kept in step with RFC 8259.
- Introducing JSONThe original one-page description of JSON with its railroad diagrams.
- RFC 4180: Common Format and MIME Type for Comma-Separated Values (CSV) FilesThe commonly implemented CSV rules: comma separators, CRLF line ends, quoting of fields that contain commas, quotes or line breaks.