JSON Formatter & Validator
Check JSON for errors, pretty-print or minify it.
Also called: JSON beautifier, JSON validator, JSON viewer.
JSON Formatter & Validator
Check JSON for errors, pretty-print or minify it.
Watch: how to use the JSON Formatter & Validator (14 seconds)
Recorded on a phone, steps written on screen, no sound.
About the JSON Formatter & Validator
Format, check and tidy JSON: it shows clear errors with the line number, indents the data so it is readable, or minifies it for sending. Your data never leaves the browser.
Formats
Pretty-print with 2 spaces (the default), pretty-print with tabs, or minify to one line for APIs and smaller files. Formatting does not change any value or the order of keys.
If the JSON is not valid, the tool shows the browser's error message, which names the problem and usually its position: a missing comma, a trailing comma, single quotes or a comment. JSON allows only double quotes and no comments.
How to use the JSON Formatter & Validator
- Enter your textType or paste your text.
- Pick the optionsoutput (the defaults suit most uses).
- Press Run toolThe result appears right under the button.
- Copy or download the resultCopy text results with Copy output; when the tool makes a picture or file, use its Download button.
This tool works inside your browser: what you enter stays on your device.
Good to know
- What you need
- You type or choose: Input text
- Where it runs
- In your browser, on your device.
- Cost
- Free, no sign-up.
Questions
Why does my JSON say it is invalid?
Common causes are a missing comma, a trailing comma or single quotes instead of double quotes.
Is my data sent anywhere?
No. Formatting happens on your device.