# JSON Formatter and Validator

Format, beautify, validate and view JSON, and see exactly which line broke it. Runs entirely in your browser, so nothing you paste is sent anywhere.

Canonical page: https://filetity.com/json-formatter

## Capabilities

- Free: Yes, with no watermark and no page limit.
- Account required: No. There is no account system.
- Processed on device: Yes. The file is read by your browser and never uploaded. There is no server to send it to.
- Formats: JSON in. Formatted JSON out, with 2 spaces, 4 spaces, tabs, or minified.
- Limits: No size limit beyond what your browser will hold in a text box. Very large documents are better handled as a file by a local tool.
- Mobile: Yes, on any modern mobile browser. Large files are limited by the memory the phone gives the browser.
- Offline: Yes, after you have used it once. Your browser keeps what the tool needs, so it then works with no network connection.

## Questions

### Is my data sent to a server?

No. There is no server. This matters more here than anywhere else on the site, because the JSON people need formatted is usually an API response with a key, a token or a customer record in it.

### Why does it tell me a line number when other formatters just say invalid?

Because the line number is the reason you opened a formatter. Browsers give a position for some malformed documents and nothing useful for others, so when the browser will not say, the text is scanned to find where it stopped parsing.

### Does sorting keys change my data?

It reorders object keys alphabetically at every depth, which JSON treats as meaningless, and leaves arrays exactly as they are, because array order is data. Sorting is off unless you ask for it.

### Is a JSON beautifier the same as a formatter?

Yes. Beautify, prettify, format and pretty-print all describe the same thing: taking JSON that arrived as one unreadable line and laying it out with indentation so a person can follow it. This page does that, and does the reverse too if you pick Minified.

### Can I use this just to check whether my JSON is valid?

That is what it does as you type. Valid JSON shows a confirmation and the byte counts; invalid JSON gets the line and column where it broke and what was expected there. You do not have to press anything, and nothing is sent anywhere to check it.

## Related tools

- [JSON diff](https://filetity.com/json-diff): Compare two JSON documents and see exactly what differs.
- [JSON to CSV](https://filetity.com/json-to-csv): Turn a JSON array into a CSV file that opens correctly in a spreadsheet.
