Runs in your browser

JSON Formatter & Minifier (Pretty & Minify)

Format or minify JSON, with clear error locations. Everything runs in your browser.

Your input is never sent to a server (processed locally) Safe to use even with sensitive data
Напредне опције
Cmd/Ctrl+Enter to format / Cmd/Ctrl+Shift+Enter to minify
У мировању
Input (JSON)
Lines 0 Знакови 0 Veličina 0 B
Your input is processed locally in the browser and never sent to a server.
Izlaz
Lines 0 Знакови 0 Veličina 0 B
Copy or download the output.
Formatted or minified JSON will appear here...

Podešavanje

Napredne opcije

How to use (3 steps)

1. Paste

Paste JSON into the input panel.

2. Format/Minify

Click Format or Minify to generate the result.

3. Copy

Copy the output and you are done.

Пречице

Shortcuts work when the input has focus.
Cmd/Ctrl + Enter
Format
Cmd/Ctrl + Shift + Enter
Minify
Cmd/Ctrl + L
Clear (with confirmation)

Example of formatted JSON

Pre
{"name":"A","items":[1,2],"meta":{"ok":true}}
Posle
{
  "items": [
    1,
    2
  ],
  "meta": {
    "ok": true
  },
  "name": "A"
}
  • Adds indentation and line breaks for readability
  • Sort keys to keep a consistent order

Notes & terminology

What is JSON formatting?

Pretty-printing JSON adds line breaks and indentation so the structure is easy to read.

What is JSON minify?

Minifying removes whitespace to make the output as small as possible.

Common errors

Trailing commas, missing quotes, and mismatched brackets are typical. This tool shows line/column details.

Savet

Indent 2 keeps diffs smaller, while indent 4 is easier to scan. Choose based on your workflow.

FAQ: JSON formatter & minifier

I get an error

We show the line and column where the JSON is broken. If possible, the input is highlighted and you can jump directly to it.

Can I use JSON with comments (JSONC/JSON5)?

Standard JSON does not allow comments. Turn on “Strip comments before parsing” if needed (not fully compatible).

Large JSON is slow

Parsing and formatting run in a Web Worker to keep input responsive. Tree view is disabled automatically for large inputs.

Da li se moji podaci šalju bilo gde?

No. Formatting, minifying, and validation run entirely in your browser.

I see \uXXXX escapes

Toggle “Unicode escape” to control whether the output uses escape sequences.