What JSON syntax errors does it detect?
Trailing commas after the last element, unmatched braces and brackets, single-quoted strings, unquoted keys, missing commas between items, invalid Unicode escape sequences (\uXXXX), and invalid number formats. Each error reports the exact line and column number.
What is the difference between JSON and JavaScript object syntax?
JavaScript objects allow unquoted keys ({name: 'alice'}), single-quoted strings, trailing commas, and comments. JSON requires double-quoted keys ({"name": "alice"}), no trailing commas, and no comments. All valid JSON is valid JavaScript, but not vice versa — this mismatch is the source of most copy-paste errors.
Can it handle large JSON files?
Yes. Processing runs locally so there is no upload size limit or server timeout. Most JSON under 10 MB formats instantly. Files above 50 MB may take a few seconds depending on your device.
What is the difference between formatting and minifying?
Formatting adds indentation and line breaks for human readability. Minifying removes all whitespace to reduce file size — typically 15–30% smaller — for production API payloads and bundle assets. This tool handles both: format for debugging, minify for deployment.
Is this JSON formatter free?
Yes — completely free, no signup required, no usage limits. It runs entirely in your browser.
Does the JSON formatter fix errors automatically?
No — the formatter reports the exact line and column of the first syntax error but does not auto-correct it. JSON has strict syntax rules and any 'fix' would require guessing your intent (for example, whether a missing comma or an extra bracket is the true problem). Use the error location to find and correct the issue, then paste again.
What is minified JSON and why would I use it?
Minified JSON has all whitespace (spaces, newlines, tabs) removed, producing a compact single-line string. It is functionally identical to formatted JSON but smaller — typically 15–30% fewer bytes. Use minified JSON in production API responses, HTTP request bodies, and application bundles to reduce payload size and speed up parsing.
What is the difference between JSON and JSONP?
JSON is a pure data format. JSONP (JSON with Padding) is a legacy browser workaround that wraps a JSON payload in a JavaScript function call — for example, callback({"key":"value"}) — to bypass the same-origin policy. JSONP is not valid JSON and cannot be parsed by JSON.parse(). Modern APIs use CORS instead; JSONP is rarely used in new development.
Does this formatter support JSON5 or JSONC?
No — the formatter uses the browser's native JSON.parse(), which implements strict RFC 8259 JSON only. JSON5 (unquoted keys, trailing commas, comments) and JSONC (JSON with comments, used in VS Code settings) are supersets of JSON. If you paste JSON5 or JSONC with comments or trailing commas, the formatter will report a syntax error. Remove non-standard syntax before formatting.
How large a JSON file can I format?
There is no server-side file size limit because everything runs in your browser. JSON under 10 MB formats instantly on most devices. Files between 10–50 MB may take a second or two. Files above 50 MB can slow down or temporarily freeze the tab on lower-powered devices. For very large JSON, consider streaming parsers or command-line tools like jq.
Can I format JSON that contains comments?
Not directly — standard JSON (RFC 8259) does not allow comments, so JSON.parse() will throw a SyntaxError. To format JSON with comments, first strip them manually or use a JSONC-aware tool. VS Code's settings.json and tsconfig.json use JSONC, which supports // comments but requires a JSONC parser rather than a standard JSON formatter.
Is this the same as using Prettier for JSON?
Functionally similar for basic formatting. Prettier applies its own opinionated style (always double quotes, specific bracket spacing) and can be configured per project. This formatter uses JSON.stringify() with configurable 2- or 4-space indent — equivalent to Prettier's JSON output for standard files. The main difference: this tool runs instantly in the browser with no install, while Prettier is a project dependency for editors and CI pipelines.