JSON Formatter & Validator
Pretty-print, minify and validate in one place. Your data never touches a server.
0 B uploaded — nothing you enter has been sent anywhere?
Other tools send what you type to a server and process it there. Even when they promise to erase it afterwards, your text sits on someone else’s machine in the meantime. Here there is no sending step at all. The more sensitive the content — passwords, contract wording, private notes — the more that difference matters. See how to verify it →
Unfold minified JSON into something readable and find exactly where it breaks
JSON from an API or a config file stops working entirely if a single comma or quote is off. This tool checks the syntax first, then either expands the JSON with 2-space indentation or squeezes it onto one line, and if something is wrong it moves the cursor to the spot where the parser gave up. Responses containing tokens never leave your browser.
A closer look
JSON is strict because machines read it, not people. Keys must be wrapped in double quotes, a comma after the last item is not allowed, and there are no comments. Syntax that works in JavaScript code, in JSON5 or in the JSONC used by some editors’ settings files is an error here. Line breaks inside a string must be written as \n rather than typed as real new lines. The tool runs the whole input through the browser’s built-in JSON parser, and if even one character breaks the rules it produces no output and reports the error instead.
When parsing succeeds, the result replaces what is in the same box. Because the output is written back from the parsed values, it can differ slightly from what you pasted: 1.0 becomes 1, 1e3 becomes 1000, an escaped character such as \u00e9 is written as é, a key that appears twice keeps only its last value, and keys that look like whole numbers, such as "1" and "2", move ahead of the other keys. On an error, the box is left untouched and the character where the problem was detected is selected.
How to use it
- Paste your JSON into the box. For a file, copy its full contents from your editor.
- Press Format (2-space indent) to expand the structure, or Minify to drop every space and line break outside strings. Both buttons validate first; on success the status line reads “Valid JSON.”
- If there is a problem you will see something like “Syntax error (near line 3): …” with the browser’s description, and the cursor jumps to the character where parsing stopped.
- Press Copy to put whatever is currently in the box on your clipboard.
When it helps
Common snags
Tip Format and Minify overwrite the text in the box, so if you need the exact original, copy it somewhere else before pressing either button.
Notes
Is it safe for API responses and config files?
Yes. Everything happens inside your browser — the JSON you paste is never sent over the network. Data containing tokens or secrets stays on your device.
Does it show where the error is?
It depends on your browser. Where the browser's error message includes a position (Chrome, Edge and other Chromium browsers), it reports the approximate line number and moves the cursor to that spot. In Firefox, Safari and others it shows the browser's own error message as-is and does not move the cursor (Firefox's message does include the line and column).