JSON Viewer

Free JSON Viewer to validate, format, and inspect JSON in your browser.

.jsonValid JSON
JSON
Preview
{
"name": "MdPdf",
"private": true,
"tools": [
{
"id": "pdf-to-md",
"ready": true
},
{
"id": "md-viewer",
"ready": true
},
{
"id": "json-viewer",
"ready": true
}
],
"privacy": {
"runsInBrowser": true,
"uploadRequired": false
}
}

Use this JSON Viewer to check JSON as you type. Paste a payload on the left to pretty-print it or show a collapsible tree. Copy or download the result; nothing is uploaded.

Why use JSON Viewer?

Validate as you type

JSON Viewer shows whether the payload is valid immediately, with line and column details when a parse error includes a position.

Format or inspect

Pretty-print for reading, minify for compact output, or switch to a tree when you need to expand nested keys.

Private by default

Open a local .json file, copy the result, and download it again without sending content to a server.

JSON is fine until it is one line, or wrong, or both

APIs return minified objects. Config files accumulate nested keys until nobody can see which brace closes which feature flag. Language models emit “JSON” that is almost valid: a trailing comma, a comment, a single-quoted string, an unescaped newline inside a value. Log pipelines dump entire payloads as escaped strings. In all of those cases you do not need a new editor as much as you need a place that will parse, point at the error, and let you look around.

This JSON viewer stays in the browser on purpose. Production tokens, customer records, and staging secrets show up in JSON more often than people admit. Formatting that payload should not require pasting it into a random website that might log the body.

API responses you cannot read in the network panel

DevTools will pretty-print, but it will not let you delete a noisy key, minify a subset, or save a fixture. Paste the body here when you are turning a live response into a test case, or when you need to send a colleague the shape without the auth header still sitting in the screenshot.

Config, manifests, and infrastructure files

package.json, appsettings, Terraform JSON, and workflow payloads are all the same problem at different scales: nested maps that you need to expand one branch at a time. Tree view is for navigation. Formatted view is for reading a full file you are about to commit.

Tool calls and structured model output

Agents pass arguments as JSON. When a call fails, the reason is often a type that should have been a string, a missing field, or a blob of Markdown stuffed into a value. Inspecting the payload as a tree is quicker than counting brackets in the trace UI. If the model wrapped JSON inside a string, unescape first so you are looking at the inner object.

When the file is “JSON” but will not parse

The viewer tells you that the input is invalid, and if the engine knows the position, it tells you the line and column. Format and minify stay disabled until the document is actually JSON. That is deliberate: pretty-printing invalid input would invent a structure that is not there.

Formatted, minified, and tree are three jobs

Formatted JSON is for reading and for diffs against other pretty-printed files. Minified JSON is for pasting into an environment variable, a CLI flag, or a size-sensitive request. Tree view is for exploring: expand one object, collapse the rest, delete a key you do not want in a sample. Hovering a line to remove a property is how you shrink a production dump down to the fields a bug report actually needs.

Large documents may skip the tree and stay in formatted view. That is a limit of running in the browser, not a prompt to upload the file somewhere else. Copy or download when you are done; the source on the left stays in sync with edits you make in the tree.

JSON Viewer FAQs

No. Parsing, formatting, and the tree view all run in your browser.

More tools