Loopy HQ LogoSupport Us
Free Developer Tool

JSON Formatter & Validator

Beautify, minify, and validate JSON with exact error locations. Payloads stay in your browser, which matters when they contain tokens or customer data.

Waiting
Output size
Keys
Values
Max depth

A validator that tells you where the problem is

"Unexpected token" is a useless error message on a 4,000-line payload. This tool translates the parser error into a line and column, prints the offending line with a caret under the exact character, and reports the structure it did manage to read: key count, value count, and nesting depth. Formatting and minifying reuse the same parse, so an invalid payload never silently produces plausible-looking output.

Frequently Asked Questions

Why does my JSON fail validation?
The four most common causes, in order: • Trailing commas after the last item in an object or array. • Single quotes instead of double quotes around keys or strings. • Unquoted keys, which are legal in JavaScript but not in JSON. • Comments, which JSON does not support at all. The error panel reports the line and column so you can jump straight to the character that broke parsing.
What does sorting keys do?
It rebuilds every object with its keys in alphabetical order, recursively, while leaving array order untouched. This makes two versions of the same payload comparable in a diff, since key order stops being a source of noise.
What is the difference between formatting and minifying?
Formatting adds indentation and line breaks so a human can read the structure. Minifying removes every optional space so the payload is as small as possible for transport or storage. Both produce identical data, just different whitespace.
Is my payload sent to a server?
No. Parsing uses the browser's built-in JSON engine and runs entirely on your machine. That matters for API responses, which routinely contain tokens, customer records, and internal identifiers you should not paste into a remote validator.
Will very large numbers stay exact?
Not always. JSON.parse converts numbers to IEEE 754 doubles, so integers beyond 2^53-1 (about 9.007 quadrillion) and high-precision decimals can lose digits on reformat. If your payload contains large IDs, keep them as strings.