JSON Formatter & Validator

JSON Formatter & Validator

Beautify, minify, and validate JSON. Errors show the exact line and column, with live document stats.

Paste JSON above to validate — errors show line & column.
—

The JSON formatter & validator beautifies, minifies, and checks your JSON in one place. Paste any JSON — an API response, a config file, or something from the browser console — and get it pretty-printed with 2-space indentation or compressed to a single line in one click.

Validation runs live as you type: invalid JSON shows the exact line and column where parsing failed, so missing commas, quotes, and braces are easy to find and fix. The tool also reports document stats — counts of objects, arrays, strings, numbers, booleans, and nulls, plus the nesting depth.

Everything runs locally in your browser. Nothing is uploaded and nothing is tracked, so it is safe to paste sensitive payloads like JWTs or private API responses.

Frequently Asked Questions

What does a JSON formatter do?
It takes compact or messy JSON and re-indents it with proper spacing (2 spaces per level) so it is easy to read. Minify does the opposite: it strips all whitespace to shrink the payload for storage or transfer.
How do I find the error in my JSON?
The validator parses your input as you type. When it fails, it reports the exact line and column where parsing stopped — check that spot for a missing comma, quote, or closing brace.
Is my JSON sent to a server?
No. All parsing, formatting, and validation happen entirely in your browser using JavaScript. Your data never leaves your device.
Why does my JSON show an error on valid-looking input?
Common causes: trailing commas, single quotes instead of double quotes, unquoted keys, or a BOM character. JSON strictly requires double-quoted keys and strings; the formatter strips a leading BOM automatically.

Related Tools

Text Counter Password Generator Unit Converter Color Converter URL Encoder / Decoder Base64 Encoder / Decoder

Like Numbrary? A small tip keeps the tools free.

Send a tip