JSON Formatter
Format, validate, minify, diff, and explore JSON — all client-side.
Empty input
Input
Formatted output
Enter valid JSON to see formatted output.
How to use it
- 1Paste your JSON into the input editor.
- 2Switch modes: Format (pretty-print), Minify (single line), Tree (collapsible explorer), or Diff (compare two payloads).
- 3Copy the result, or click through the tree to drill into nested keys.
- 4On Chrome with the Prompt API enabled, hit Explain to get a 2–4 sentence Gemini Nano summary of what the payload is and what its key fields mean.
Common use cases
- Debug API responses and find malformed or missing fields.
- Minify a payload to fit inside a query parameter or test fixture.
- Diff a before-and-after payload to track exactly what changed.
- Drill into deeply nested configuration files with a collapsible tree.
- Get a plain-English summary of an unfamiliar webhook or API payload via on-device AI.
Frequently asked questions
- Does it work offline?
- Yes — once the page is loaded, everything runs locally with no network calls.
- What's the maximum size?
- Your browser's memory is the only limit. Files up to a few megabytes feel instant; multi-megabyte payloads may take a moment to parse.
- Does it accept JSON5 or JSONC (with comments)?
- No, only strict JSON per RFC 8259. Strip comments and trailing commas before pasting.
- Is my data sent anywhere?
- No. All parsing, formatting, and diffing happens in your browser. Nothing is uploaded — the AI summary uses Chrome's on-device Gemini Nano, so even AI runs locally.
- How does the AI Explain button work?
- It uses Chrome's built-in Prompt API (Gemini Nano), which runs the model on your device. There's no API call to OpenAI / Google / anyone — your JSON never leaves your machine. The button only shows up if your browser supports it (Chrome 138+, with the optional model downloaded). On every other browser the tool works normally without it.
Related tools
Base64 Encode / Decode
Encode and decode text and files to and from Base64.
HTML Live Preview
Write HTML, CSS, and JavaScript and see the result instantly.
JWT Decoder
Inspect the header, payload, and expiry of any JSON Web Token — with optional on-device AI that explains what the token grants in plain English.
SQL Formatter
Beautify, format, and minify SQL queries for any dialect — with optional on-device AI that explains what a query does in plain English.
Unix Timestamp Converter
Convert Unix timestamps to dates and back, in any timezone.
Hash Generator
Generate MD5, SHA-1, SHA-256, and SHA-512 hashes in your browser.
JSON to TypeScript
Generate TypeScript interfaces or type aliases from JSON.
Markdown to PDF
Convert Markdown to a beautifully styled PDF in your browser.
QR Code Generator
Make QR codes for websites, Wi-Fi passwords, contact cards, social handles, email, SMS, and more. Download as PNG or SVG — or as a ZIP with one branded QR per social platform.
Password Generator
Generate strong, secure passwords in your browser. Nothing is sent or saved to any server.
Text Diff
Compare two pieces of text and see line-by-line, word-by-word, or character-by-character what changed.
UUID / ULID Generator
Generate UUID v4, UUID v7, or ULID identifiers in bulk, instantly in your browser.
SVG to PNG / JPEG / WebP
Convert SVG to PNG, JPEG, or WebP at any size — quality slider, transparent or colored background, copy to clipboard. Free, in your browser.
URL Encoder / Decoder
Encode or decode URLs and query parameters with component-vs-full-URI scope, plus a query-string breakdown. Free, in your browser.
Regex Tester
Test JavaScript regular expressions with live highlighting and a capture-group inspector — plus an AI regex generator that turns plain-English descriptions into regex (on-device Gemini Nano).
Color Converter
Convert colors between HEX, RGB, HSL, HSV, and OKLCH, and generate tint, shade, and harmony palettes. Free, in your browser.
HTML ↔ Markdown Converter
Convert HTML to Markdown or Markdown to HTML with a live preview. GFM tables, fenced code blocks, inline formatting. Free, in your browser.
Cron Builder
Build cron expressions visually or describe the schedule in plain English and let on-device AI write it for you. Plain-English explanation, next 5 runs, presets.