Why minify JSON?
Indentation and line breaks make JSON readable for people but add bytes that machines do not need. Minifying removes every optional space, tab and newline, which typically shrinks pretty-printed JSON by 15–40%. Smaller payloads mean faster API responses, cheaper storage and less bandwidth on mobile networks. The data itself — keys, values and their order — stays exactly the same.
This minifier parses the JSON before minifying it. A simple “remove whitespace” regular expression would also delete spaces inside strings and could silently corrupt your data; parsing guarantees that only insignificant whitespace is removed and that the result is valid.
How to minify JSON
- Paste or upload your JSON.
- The minified version appears instantly with original size, new size and percentage saved (measured in UTF-8 bytes).
- Copy it or download it as a
.jsonfile.
Example
Before (64 bytes)
{
"name": "Asha",
"skills": [
"go",
"sql"
]
}After (37 bytes)
{"name":"Asha","skills":["go","sql"]}Minify vs. gzip
Web servers usually also compress responses with gzip or Brotli. Compression and minification work well together: minify first to remove redundant whitespace, then let the server compress the result. To turn minified JSON back into readable form, use the JSON Formatter.
Frequently asked questions
Will minifying change my data?
No. Only whitespace between tokens is removed. Spaces inside string values are kept.
Why is the saving 0%?
Your JSON was already minified.
Can I reverse it?
Yes. Paste the minified JSON into the JSON Formatter to pretty-print it again.
Is my JSON uploaded?
No. Minification happens in your browser.