Base64 Encoder
Encode and decode Base64, Base64URL and percent-encoded URL text instantly.
Format messy JSON into readable, indented output, minify it back down for transport, and validate it with the exact line and column of any syntax error. Nothing is sent anywhere, which matters when your payload contains API keys, tokens or customer data.
// Formatted output will appear here
Four steps, no account, nothing uploaded.
Paste into the input panel, or load a .json file from your device. The file is read locally and never uploaded.
Select an indentation width of two spaces, four spaces or tabs, and optionally enable alphabetical key sorting.
Format produces indented output, Minify strips all optional whitespace, and Validate confirms the document parses and reports where it fails if not.
Use Copy to place the output on your clipboard, or Download to save it as a file.
Built so your files never have to trust a server.
API responses often carry tokens and personal data. Nothing here is transmitted or logged, so you can paste production payloads without a second thought.
Invalid JSON is reported with the line and column of the failure and the offending snippet, instead of a generic "parse error".
Format with two spaces, four spaces or tabs, and optionally sort object keys alphabetically for easier diffing.
Copy the result to your clipboard or save it as a .json file without leaving the page.
Everything people ask about the JSON Formatter.
No. Parsing and formatting use the browser JavaScript engine directly in your tab. No request carrying your JSON is made, so pasting payloads containing credentials or customer data is safe.
The most common causes are a trailing comma after the last element, single quotes instead of double quotes, unquoted object keys, comments (which JSON does not allow), or a stray non-breaking space pasted from a document. The error message names the exact line and column, which usually identifies the culprit immediately.
Formatting adds newlines and indentation so the structure is readable by people. Minifying removes every optional space and newline to produce the smallest valid payload for network transport. Both represent exactly the same data.
Files of a few megabytes format quickly. Extremely large documents may briefly freeze the tab, because JSON.parse is synchronous. For files above roughly 50 MB, a streaming command-line tool such as jq is a better fit.
No. Validation follows the strict JSON specification (RFC 8259), so comments, trailing commas, single-quoted strings and unquoted keys are all reported as errors. That strictness is intentional — it catches exactly the problems that break real parsers.
Only its whitespace. Key order is preserved unless you enable sorting. Note that JavaScript numbers are IEEE 754 doubles, so integers beyond 2^53 may lose precision on a parse-and-reprint round trip — a limitation of every JSON tool built on a JavaScript engine.
Yes. Enable "Sort keys" before formatting and every object is emitted with its keys in alphabetical order, recursively. This is useful for producing stable diffs between two versions of a config file.
More free utilities that run entirely in your browser.
Encode and decode Base64, Base64URL and percent-encoded URL text instantly.
Count words and characters live, with readability scoring and keyword density.
Convert PNG, JPEG and WebP images and compress them with a quality slider.