How to view JSON online
- Load the JSON. Paste it, drag a
.jsonfile onto the box, or click Open file. Files over 5 MB are read straight into the viewer and not put in the text box, which keeps the page responsive. - Read the tree. The first two levels open automatically. Click a caret to fold or unfold a branch, or use Level 1/2/3 to set how much is open.
- Find what you need. Type in the search box to highlight every key or value that contains the text. The arrows jump between matches and open the branches around each one.
- Copy the path. Click any node and the path bar shows where it lives, for example
$.data.items[0].id. Copy the path, or copy that node's value as formatted JSON.
JSON reader: open and read .json files
You do not need an editor or IDE to read a JSON file. This JSON reader opens .json, .geojson, .har (browser network exports), source maps and plain-text files that contain JSON. Everything is read locally with the browser's File API. Common formats read well here:
- API responses and exports: Postman collections, Stripe or Shopify exports, Firebase dumps, Google Takeout, and Twitter/X or Instagram data downloads.
- Config and manifests:
package.json,composer.json,tsconfig.json(comments are handled by View anyway), andappsettings.json. - Logs in JSON Lines:
.jsonl/.ndjsonfiles hold one object per line, which is not a single JSON document. The viewer offers to repair them into an array so you can browse every line.
If a file does not parse, you get the line and column of the first error, and a View anyway button. That button runs the same clean-up as the JSON formatter and cleaner: it removes comments and trailing commas, fixes quotes and closes truncated brackets. Then the file opens as a tree.
JSON tree viewer: tree, raw and table views
The three views show the same parsed data in different ways:
| View | What you see | Best for |
|---|---|---|
| Tree | Foldable nodes. Objects show their key count {4} and arrays their length [12]. A collapsed object previews its first keys, and every value is coloured by type. | Understanding the shape of unfamiliar data and drilling into one branch |
| Raw | The whole document pretty-printed with 2-space indentation and syntax colours. Key order and number formatting are unchanged. | Reading top to bottom and copying large sections |
| Table | An array of objects as rows and columns: the selected array, or the first array of records found in the document | Scanning records, spotting missing fields, and comparing values across items |
Strings are shown as JSON strings, so a line break inside a value appears as \n. That way you can see exactly what the data contains. URLs inside strings are clickable. In very long strings the first 300 characters are shown, and the full value is always available with Copy value.
JSON navigator: copy the path to any value
When you know where a value is, you usually want to use it in code, a test or a query. The path bar shows the location of the selected node in four notations. Pick the one that matches where you will paste it:
| Notation | Example | Use it in |
|---|---|---|
| JSONPath | $.data.items[0]['unit price'] | JSONPath testers, Postman tests, Kubernetes kubectl -o jsonpath, AWS Step Functions, Jayway / Python jsonpath libraries |
| JavaScript | data.data.items[0]["unit price"] | Browser console, Node.js, TypeScript. Add ?. for optional chaining. |
| jq | .data.items[0]."unit price" | The jq command line, GitHub Actions and shell scripts |
| Python | data["data"]["items"][0]["unit price"] | Python after json.load(), and Pandas json_normalize record paths |
Array indices start at zero in every notation, so the first element is [0]. Keys that are not plain identifiers, such as those with spaces, dashes or a leading digit, switch to bracket or quoted form automatically.
Search inside JSON
Search matches keys and values without regard to case, including the text of numbers, true, false and null. It works on the parsed data, not the DOM, so it also finds matches in branches you have not opened yet. Moving to a match opens its parent branches. The counter shows your position, for example 3 / 41. Press Enter for the next match and Shift+Enter for the previous one.
Viewing large JSON files
Many online viewers build the whole tree up front and freeze on a 20 MB file. This viewer renders branches only when you open them, and very long arrays 200 items at a time. On a typical laptop, a 50 MB file with a million values parses in a second or two and opens straight away. The real limit is your browser's memory, usually a few hundred megabytes of JSON. Expand all stops after 20,000 nodes so a huge document cannot lock up the tab. For files in the gigabyte range, use a streaming tool on the command line:
jq '.items | length' big.json # count items without opening an editor
jq -c '.items[] | select(.status=="failed")' big.json | head
jless big.json # interactive terminal JSON viewer
Read JSON in code
JavaScript
const res = await fetch('/api/orders');
const data = await res.json();
console.log(data.items?.[0]?.id); // optional chaining for missing branches
console.dir(data, { depth: null }); // Node.js: print the full tree
Python
import json
with open("data.json", encoding="utf-8") as f:
data = json.load(f)
print(data["items"][0]["id"])
print(json.dumps(data, indent=2)[:2000]) # peek at the first 2,000 characters
jq
jq 'keys' data.json # top-level keys
jq '.items[0]' data.json # first record
jq 'paths | map(tostring) | join(".")' data.json | head # list every path
Frequently asked questions
How do I view a JSON file online?
Click Open file (or drag the file onto the input box) and choose the .json file. The viewer reads it locally, validates it and shows it as a collapsible tree. You can switch to the raw or table view, search it and copy paths. The file is never uploaded.
Can it open large JSON files?
Yes. The tree renders branches only when you open them and shows long arrays 200 items at a time, so files of tens of megabytes stay responsive. Files over 5 MB are kept out of the text box for speed. The practical limit is your browser's memory, typically a few hundred megabytes.
How do I get the path of a value in JSON?
Click the node in the tree. The path bar shows its location as JSONPath (for example $.data.items[0].id), and you can switch the notation to JavaScript, jq or Python and copy it with one click.
What is the difference between the tree view and the raw view?
The tree view shows nested, foldable nodes with type colours and item counts, which is best for exploring structure. The raw view is the same document pretty-printed as text, which is best for reading top to bottom or copying large parts.
Why do some strings show \n instead of a line break?
The viewer shows string values exactly as they are stored in JSON, where a line break inside a string is written as the escape \n. Copy value gives you the JSON, and your code will see a real line break when it parses the string.
Does the viewer change key order or numbers?
No. Keys appear in the order they have in the file, and numbers are shown exactly as written, so large IDs such as 1453729827150749696 are not rounded the way JavaScript's JSON.parse would round them.
Is my JSON uploaded anywhere?
No. Parsing, rendering and search all run in JavaScript in your browser. Nothing is sent to a server, so you can view confidential exports and logs safely.