Code & JSON Tools
About the JSON Formatter
The JSON Formatter validates JSON, pretty-prints it with your choice of indentation, minifies it to one line and can sort object keys alphabetically. If the JSON is invalid, it tells you what went wrong so you can fix it.
In-depth guideHow to Format and Validate JSON (and Fix the Most Common Errors) →
- Category
- Code & JSON Tools
- Price
- Free
- Account
- Not required
- Runs
- Entirely in your browser
How to use the JSON Formatter
- Paste your JSON.
- Pick an indentation (or minify) and optionally sort keys.
- Copy the formatted JSON.
Privacy
Everything runs in your browser: what you type or paste is processed by JavaScript on your device, not on a server. If you are signed out, nothing is saved at all. If you sign in with Google, your inputs and settings are saved privately to your account so they sync across devices.
Frequently asked questions
Is the JSON Formatter free?
Yes. JSON Formatter is completely free with no sign-up, no usage limits and no watermarks.
Is my data private?
Yes. The JSON Formatter processes everything in your browser. Signed out, nothing is saved; signed in, your inputs sync privately to your own account.
Why is my JSON invalid?
The usual causes are trailing commas, single quotes instead of double quotes, unquoted keys, comments, or missing brackets. Standard JSON allows none of those.
Does formatting change my data?
No. Pretty-printing and minifying only change whitespace. Sorting keys changes key order, which JSON treats as insignificant.
Does it work on my phone?
Yes. Toolbench runs in any modern browser on desktop, tablet or phone — there is nothing to install.
Related code & json tools
- HTML ⇄ MarkdownConvert both ways with a rendered preview.
- Base64 / URL EncodeEncode and decode Base64, URL components and HTML entities.
- JSON Viewer & EditorExplore JSON as a collapsible tree, edit values inline and copy paths.
- JSON ValidatorCheck JSON and pinpoint errors by line and column.
- JSON MinifyStrip all whitespace from JSON.
- CSV to JSONConvert CSV rows into a JSON array.
- TSV to JSONConvert tab-separated rows (e.g. pasted from a spreadsheet) into JSON.
- XML to JSONConvert XML into JSON; attributes become @keys.
Last updated