Minify JSON for the smallest payload
Strip every byte of unnecessary whitespace. Useful for API responses, configs, and anywhere bandwidth matters.
Ready when you are.
Paste JSON on the left, or click Sample to try a quick example. Validation runs as you type — entirely in your browser.
When to minify
Minify before shipping JSON over the wire — REST responses, GraphQL payloads, config files embedded in build outputs, or any place where size adds up at scale. Combined with gzip or brotli compression, minified JSON is dramatically smaller than pretty-printed input.
For human review and version control, prefer the formatter instead.
Examples
{
"ok": true,
"count": 3
}{"ok":true,"count":3}30 bytes → 21 bytes (30% smaller).
{
"items": [
{ "id": 1 },
{ "id": 2 }
]
}{"items":[{"id":1},{"id":2}]}55 bytes → 29 bytes (47% smaller).
{
"sub": "user_123",
"iat": 1700000000,
"exp": 1700003600
}{"sub":"user_123","iat":1700000000,"exp":1700003600}JWT payloads are always minified before base64 encoding.
Use cases
- Reducing API bandwidth
Shave 20–40% off response sizes before gzip even runs. Adds up at scale.
- Embedding JSON in code
When inlining config into a JS bundle or HTML attribute, minified JSON keeps source files small.
- Building JWTs by hand
JWT payloads must be minified JSON before base64 encoding — paste, minify, encode.
- Cache keys
A canonical, minified form makes a stable cache key when memoizing on JSON inputs.
- QR-code data
Smaller JSON means a less dense QR code — easier to scan in low light.
Frequently asked questions
What is JSON minification?+
Removing all non-significant whitespace (spaces, tabs, newlines) from a JSON document so the payload is as small as possible.
Will minification change my data?+
No. JSON whitespace is purely formatting — the parsed value is identical before and after.
Why minify JSON?+
Smaller payloads transfer faster and cost less bandwidth. Minified JSON is the standard for API responses, embedded configs, and JSON Web Tokens.
Can I un-minify minified JSON?+
Yes — paste it into the formatter to pretty-print it again. The structure is fully preserved.