Developer tool
JSON Formatter and Validator
Free JSON formatter and validator: check syntax, see the error line and indent with two spaces, four spaces or tabs. Your JSON is processed in your browser.
Your file never leaves your device.
Runs locally in your browser
Your text is not uploaded.
What is a JSON formatter and validator?
A JSON formatter and validator checks that JSON text follows the JSON syntax rules and, when it is valid, rewrites it with indentation and line breaks so it is easy to read. File ICU’s tool explains any syntax error and runs in your browser.
Simple steps
How it works
- 01
Paste JSON into the editor.
- 02
Choose an indentation size and review any error line.
- 03
Copy the formatted JSON or clear the editor.
Good to know
Frequently asked questions
How do I format and validate JSON online without sending it anywhere?
Paste your JSON into the JSON Formatter and Validator and choose an indentation size. Valid JSON is shown neatly indented; for invalid JSON the output explains the error and the editor marks the line when the browser reports it. Parsing happens in your browser, so the data is not sent to a server.
Does formatting change JSON values?
No. Formatting changes whitespace only; the parsed JSON data stays the same.
How are syntax errors shown?
The output explains the parse error, and the editor marks the reported source line when the browser provides a line position.
Which indentation sizes are available?
Choose two spaces, four spaces, or tabs.
Does validation send JSON to a server?
No. Parsing and formatting happen locally in your browser.
Can this repair invalid JSON automatically?
It reports syntax errors but does not guess how you intended to fix the data.
Why does my JSON show an error?
Strict JSON does not allow comments, a comma after the last item, single quotes or unquoted keys. The message names the problem and the line is highlighted, so you can fix it and paste again.
What does the JSON validator check?
That the text is valid JSON: matching brackets and braces, double-quoted keys and strings, and only allowed values (text, numbers, true, false, null, objects and arrays). It does not check your data against a schema.
Can it minify JSON?
No. This tool adds indentation and line breaks so JSON is easy to read. It does not remove whitespace to make JSON smaller.