Data / JSON
JSON Formatter
Turn compact JSON into an indented structure or remove unnecessary whitespace. Invalid input stays unchanged and gets a syntax error instead.
Formatting does not change the JSON value
The formatter parses the input, then serializes the same value with two-space indentation. Minify uses the same parse-and-serialize step without indentation. Property order is retained by the browser's JSON implementation, while insignificant whitespace is replaced.
Finding a syntax error
When the browser reports a character position, the tool derives a line and column from the original text. Error wording can vary slightly between browsers, but the original parse error is always displayed rather than hidden behind a generic message.