JSON Formatter, Validator & Tree Viewer

Paste JSON. Format it, validate it, repair it, explore it as a tree. All in your browser.

All processing happens in your browser. Your data never leaves your device.

JSONYard is a free online JSON formatter and validator that pretty-prints, minifies, and checks JSON syntax against RFC 8259, then explores the result as an interactive tree. Every operation runs entirely in your browser — your JSON is never uploaded, logged, or sent to any server.

What you can do with JSONYard

Format & minify

Pretty-print JSON with 2-space, 4-space, or tab indentation. Strip all whitespace to compact one line.

Validate

Catch syntax errors with the exact line and column. Click to jump to the problem.

Tree view

Explore deeply nested JSON without scrolling forever. Collapse, expand, copy paths and values.

Repair broken JSON

Trailing commas, single quotes, comments, unquoted keys — Repair mode fixes them and tells you what changed.

Large files

Files over 200KB are parsed off-thread in a Web Worker so the UI never freezes.

Share via URL

Encode small payloads in the URL hash. Nothing is sent to a server — the hash stays in your browser.

How to use it

  1. Paste, drop, or upload your JSON into the left pane.
  2. Click Format (or press Ctrl+Enter) to pretty-print, or Minify (Ctrl+M) to compact.
  3. Switch the right pane to Tree view to explore nested structures.
  4. If the input is broken, click Repair — JSONYard will fix what it can and explain the changes.
  5. Copy, download, or share the result.

Frequently asked questions

Is my JSON sent to a server?
No. JSONYard runs entirely in your browser using JavaScript. You can confirm this yourself by opening your browser's developer tools, switching to the Network tab, and watching for outbound requests as you paste and format. There aren't any.
How big a file can I format?
Files larger than about 200KB are parsed in a Web Worker, which keeps the UI responsive while the worker handles parsing. We've tested 50MB+ files comfortably. Beyond that, you're bounded by your browser's available memory.
What does "Repair" do?
Repair mode accepts common JSON-ish inputs and fixes them: trailing commas at the end of arrays and objects, single-quoted strings, // line and /* block */ comments, and unquoted keys. After repairing, it shows a list of what it changed.
Can I share my formatted JSON via a link?
Yes — the Share button encodes small payloads in the URL hash (after #). Because URL hashes are never sent to the server, the data still stays in the browser. Large payloads can't be shared this way — use Download instead.
What's the difference between format, beautify, and pretty-print?
Nothing. All three are names for the same operation — adding indentation and newlines so JSON is readable. Minify is the opposite: it strips all unnecessary whitespace so the JSON takes up less space on the wire.
Do you use cookies or tracking?
We use localStorage to remember your theme and indent preferences. We don't set tracking cookies, fingerprint your browser, or analyze your JSON content. If we add ads in the future, we'll display a consent banner first as required by law in the EU and California.
Why does my number lose precision after formatting?
JavaScript's JSON.parse converts every number to a 64-bit float. Numbers larger than 253−1 (about 9 quadrillion) lose precision. If you're working with big IDs, transmit them as strings — that's a JSON design choice, not a bug in any formatter.

Keyboard shortcuts

  • Ctrl+Enter — Format / Beautify
  • Ctrl+M — Minify
  • Tab in the input — insert two spaces