curly{bits}

Format, validate and convert JSON. Nothing leaves your browser.

curlybits / JSON Minifier

JSON Minifier

Remove every unnecessary space and line break from JSON to make it as small as possible, and see exactly how much you saved.

Input JSON
Minified output

      

How to use the JSON Minifier

  1. Paste formatted JSON into the left box.
  2. The minified version appears on the right, with the bytes and percentage saved below.
  3. Click Copy and paste it into your config, request body or database field.

Why minify JSON?

Indentation makes JSON readable for people but adds bytes that machines don't need. Minifying is useful when you are:

  • Sending JSON in API requests or responses, where smaller payloads load faster.
  • Storing JSON in a database column, environment variable or URL parameter.
  • Embedding config inside HTML or JavaScript.

Minifying never changes the data itself. Keys, values and array order stay exactly the same; only whitespace between tokens is removed. Spaces inside string values are kept.

Minify vs. compress

Minifying typically saves 10–40% on indented JSON. Servers usually also apply gzip or Brotli compression on top, and the two stack: minified JSON still compresses well.

Frequently asked questions

Does minifying change my data?

No. Only whitespace outside strings is removed. The parsed result is identical to the original.

Does the minifier also validate JSON?

Yes. If the input is invalid you'll see the error and its line and column instead of output.

How do I turn minified JSON back into readable JSON?

Use the JSON Formatter. It adds indentation and line breaks back.

Is there a size limit?

There's no fixed limit. Several megabytes work fine in a modern browser, since nothing is uploaded.

Add this json minifier to your website

Free for blogs, schools and businesses. Copy the code below and paste it into your page's HTML. The tool works exactly like this one and runs in your visitors' browsers, so nothing is uploaded. Please keep the credit line so others can find it too.

Preview embed ↗