JSON Minifier

Skip to editor
Explorer
Open Files

No files open

0 files open

jsoneditor.io v2

No file open

Create a new file or open an existing one from the sidebar

JSONUTF-8
Spaces: 2

How do I minify JSON?

To minify JSON, paste it above and press Minify. All the indentation, line breaks and spaces between tokens are removed, which leaves exactly the same data on a single line, and Format brings the indentation back whenever you need to read it again.

Keys, values and key order all stay the same, so the minified JSON parses to identical data. It's handy for request bodies, environment variables that hold JSON and fixtures you want on one line.

  1. Paste your JSON into the editor.
  2. Press Minify in the toolbar.
  3. Copy the result, or press Save to download it.

Example

Formatted JSON
{
  "id": 7,
  "name": "Ada Lovelace",
  "roles": [
    "admin",
    "editor"
  ],
  "active": true,
  "lastLogin": null
}
Minified
{"id":7,"name":"Ada Lovelace","roles":["admin","editor"],"active":true,"lastLogin":null}

Questions people ask

Does minifying change my data?

No, it only removes whitespace outside of strings. Spaces inside your string values are left alone.

Is minifying the same as compressing?

They're related. Minifying makes the text shorter, while compression like gzip encodes it into a smaller binary form, and they stack nicely. If your server already gzips responses, minifying saves less than you'd expect over the network, though it still helps for storage and logs.

Is my data uploaded anywhere?

No, this runs entirely in your browser, so nothing you paste is sent to a server. The only feature that sends data anywhere is the optional AI assistant, and only when you actually ask it something.

Read the guideHow to Minify JSON and Why It Matters