Skip to content
BEAD

JSON Formatter & Validator

Pretty-print, minify, and validate JSON.

Output
0 bytes

🔒 Parsing happens entirely in your browser.

About this tool

Uses the browser's native JSON.parse and JSON.stringify. Errors point to the byte offset reported by the parser, which usually pinpoints the bad character.

Frequently asked

Why not just use JSON.stringify(x, null, 2) in DevTools?

You can, but only when you already have the value in a JS context. The formatter accepts pasted text — including JSON pulled out of logs or curl responses — and validates it as it formats, surfacing parse errors with positions.

What indent should I pick?

2 spaces matches Prettier and most config files. 4 spaces matches the Python convention. Tab is best when the file ships to mixed environments. Whatever you pick, stick with it across a project.

Does it sort keys or otherwise rewrite the structure?

No. The formatter only normalizes whitespace. Keys stay in their original order, numbers stay in their original form, and strings are preserved byte-for-byte.

You might also like

Used in these workflows