LocalFirstTools.com — data tools that never leave your device
No upload — everything runs on your device

JSON Formatter & Validator

Pretty-print, minify and validate JSON in your browser. Nothing is uploaded.

The JSON Formatter parses with the browser's own JSON.parse and reports the first RFC 8259 violation with its exact line and column; the document never leaves the browser tab.

Input
Output

Formatted JSON will appear here.

Valid JSON10 lines151 BValidated locally

What does the JSON Formatter do?

A JSON formatter pretty-prints compact or minified JSON, minifies it back, and reports syntax errors with a line and column. Use it for API payloads, config files and copy-paste blobs that need to be readable.

How does the JSON Formatter work?

Paste JSON, drop a .json file, or load the sample. Format rewrites with two-space indentation. Minify removes whitespace. Sort keys orders object keys alphabetically. Validation uses your browser's JSON.parse — no network request.

Does this upload my JSON?

No. This page never sends your input to a server — formatting, decoding and hashing all run in this tab, on this device.How that works.

Frequently asked questions

Does this upload my JSON?

No. Parsing and formatting run in this tab. LocalFirstTools has no server endpoint that receives the text you paste.

How do I fix an Unexpected token error?

The status bar points at the line and column of the first syntax problem — a trailing comma, a missing quote, or a comment. JSON does not allow comments or trailing commas; remove them and format again.

What is the difference between format and minify?

Format (pretty-print) adds indentation and line breaks so people can read the document. Minify emits a single compact line, which is smaller to copy into logs or requests.

Can I format JSON with comments?

Standard JSON cannot contain comments. If your file uses // or /* */ it is JSONC, not JSON. Strip comments first, then format.

Related tools

Browse alljson toolsor thefull tool directory.