How to View JSON Online
Open a local file or paste JSON, then use the tree view. Expand objects and arrays to inspect their contents without reading a long serialized line. A valid document is required before the tree can be built.
Explore JSON With a Collapsible Tree
Collapsible branches let you focus on one part of a response. Arrays use positional indexes while objects use property names. Collapse unrelated branches when tracing one value through a deeply nested payload.
Search Nested Keys and Values
Use the search control to locate matching keys or values in the output. Search is a navigation aid, not a schema check. Use JSONPath Tester when you need a repeatable query that selects values from arrays and nested objects.
JSON Viewer vs Formatter and Editor
A viewer is for inspection, a formatter controls whitespace and an editor changes source text. They can share parsing features while serving different tasks. Use the editor for deliberate changes and the diff tool to review their effect.
Working With Large JSON Files
The browser must hold the input, parsed data and rendered output in memory. Very large or deeply nested documents may feel slow. Work on a representative subset first and keep the original file outside the browser.
More examples and technical details
Why a Tree View Beats Raw Text for Large JSON
Formatted text and a tree view solve different problems. Text is the right tool when you are editing, diffing, or copying. A tree is the right tool when you are exploring a document you did not write and do not yet understand, which describes most encounters with a third party API.
The advantage comes down to three things. First, collapsing: a tree lets you shut every branch and see the top-level shape in five lines instead of five thousand, then open only the branch you care about. Flat text cannot hide anything. Second, shape recognition: with children collapsed, an array of 300 records reads as one line telling you it holds 300 records, so you immediately know whether you are looking at a list, a wrapper, or a deeply nested config. Third, path discovery: a tree shows you where a value sits in the hierarchy, so you can write the accessor for it without counting braces.
A tree also makes absence visible in a way text does not. Scanning collapsed siblings side by side, a record missing a field or holding null where its neighbours hold objects stands out immediately, and that is usually the bug you were looking for.
The Six JSON Data Types
Everything in a JSON document is one of six types. Knowing the list is useful when reading a tree, because the type of a node tells you what you can do with it and, just as often, tells you what the API author had to work around.
| Type | Example | Notes |
|---|---|---|
| string | "warehouse-3" | Double quoted, UTF-8 text. The only type that can hold arbitrary characters, via escapes where needed. |
| number | 42, -0.75, 6.02e23 | One numeric type covering everything. There is no separate integer type and no decimal type. |
| boolean | true, false | Lowercase only. Some APIs send 1 and 0 or the strings yes and no instead, which are not booleans. |
| null | null | An explicit empty value. Different from a key that is absent altogether, a distinction many APIs rely on. |
| object | {"id": 7} | Unordered set of string keys to values. Keys should be unique; behaviour on duplicates varies by parser. |
| array | [1, "two", null] | Ordered list. Elements may be of mixed types, though most real schemas keep them uniform. |
Three absences matter more than the six presences. There is no date type, so timestamps travel as ISO 8601 strings such as 2024-11-08T14:03:00Z or as epoch numbers, and it is entirely up to the consumer to know which. There is no integer and float distinction, so an id and a price are the same type to the parser, and JavaScript will hand both back as double precision floats. And there is no comment syntax, which is why so many configs carry an unused key holding a human-readable note.
Understanding JSON Paths
A JSON path is an address for a value inside a document. Dot notation steps into an object key and bracket notation selects an array index or a key containing characters that dot notation cannot express. It is the same syntax you use to read the value in JavaScript, which is why it is worth reading paths off a tree directly. Take this document.
{
"org": "Northwind",
"data": {
"users": [
{
"id": 11,
"email": "ana@northwind.test",
"roles": ["admin", "audit"],
"address": { "city": "Porto", "postcode": "4000-123" }
},
{
"id": 12,
"email": "kai@northwind.test",
"roles": [],
"address": null
}
],
"counts": { "active": 1, "invited": 1 }
}
}Every path below is evaluated against it. Note how naturally the two notations mix as you alternate between objects and arrays.
| Path | Resolves to |
|---|---|
| org | "Northwind" |
| data.counts.active | 1 |
| data.users | the array of two user objects |
| data.users[0].email | "ana@northwind.test" |
| data.users[0].roles[1] | "audit" |
| data.users[0].address.city | "Porto" |
| data.users[1].roles | [] (present but empty) |
| data.users[1].address.city | an error, since address is null |
| data.users[2] | undefined, the index is out of range |
Two of those rows are the interesting ones. Reading a property of null throws, which is why defensive code uses optional chaining such as data.users[1].address?.city. And an out of range index returns undefined rather than throwing, so a missing record fails silently further downstream. Use bracket notation with a quoted string for awkward keys, as in obj["content-type"], since a hyphen is not valid in dot notation.
Working With Large Files
Browser-based viewers have real limits, and it helps to know where they are before you paste a 200 MB export into one. The parsed structure typically occupies several times the size of the source text, because every string, number, and object carries per-value overhead in the runtime. A 50 MB file can therefore reach several hundred megabytes of live objects, and rendering a node for every value multiplies that again.
Collapsing helps directly here, not just visually. A viewer that only creates DOM nodes for expanded branches keeps the rendered node count in the hundreds regardless of document size, so scrolling stays smooth. Parsing remains the fixed cost you cannot avoid.
Past a few hundred megabytes, stop loading the whole document. Use a streaming approach instead: a jq pipeline reads the file incrementally and emits only what you asked for, so memory stays flat no matter how large the input is.
# pull one field from every record without loading the file
jq '.data.users[] | {id, email}' export.json > slim.json
# count records to understand the shape first
jq '.data.users | length' export.jsonFor newline-delimited JSON, where each line is its own document, the same idea applies with standard shell tools: take the first few thousand lines, view those, and only reach for the full file once you know what you are looking for.
When you need to edit rather than explore, the JSON Editor and the JSON Formatter are the next stops. Browse the full collection of free JSON tools to find the right one for the job.
Standards and references
Frequently asked questions
How do I view a JSON file online?
Use the local file control or paste JSON, then select Tree view.
Can I expand and collapse nested JSON?
Yes. Expand and collapse object and array branches to navigate nesting.
What is the difference between a JSON viewer and formatter?
A viewer helps inspect structure; a formatter produces readable serialized text. This viewer includes both representations.
Can I search inside large JSON data?
The search control helps locate values and keys. Browser memory and rendering limit very large documents.
Does the viewer upload my JSON?
No. Input is processed in this browser tab and is not uploaded by the tool. Copy and download are actions you control; ordinary page analytics do not receive tool input.