JSON Formatter & Validator

JSON Formatter & Validator

Format, Validate, Minify & Analyse JSON — 100% browser-side, completely private

JSON Editor

Input JSON
Output Ready
Input Size
Nesting Depth
Total Keys
Array Items
JSON Complexity
Tip: Press Format to auto-indent your JSON. Use Minify to strip whitespace for production API payloads. All processing runs entirely in your browser — no data is ever sent to any server.

How It Works

1
Paste Your JSON
Paste raw, minified, or poorly-formatted JSON into the input box.
2
Choose an Action
Click Format to pretty-print, Minify to compress, or Validate to check for errors.
3
Copy or Use Output
The processed JSON appears on the right. Use Copy to grab it in one click.

JSON Format Rules (ECMA-404 / RFC 8259)

// A JSON value must be one of: string"enclosed in double quotes" number42 | 3.14 | -7 | 1.2e10 booleantrue | false nullnull object → { "key": value, … } ← keys MUST be strings array → [ value, value, … ] // Common mistakes this validator catches: ✗ Trailing commas → { "a": 1, } ✗ Single quotes → { 'key': "value" } ✗ JS comments → // not allowed in JSON ✗ Unquoted keys → { key: "value" }

JSON Data Type Reference

TypeExampleNotesRFC 8259
String "Hello World" Must use double quotes; escape special chars with \ §7
Number 42, -3.14, 1e5 No octal/hex; NaN and Infinity are not valid §6
Boolean true, false Lowercase only — True or FALSE will fail §3
Null null Represents absence of a value §3
Object {"k":"v"} Unordered key-value pairs; keys must be strings §4
Array [1,"a",true] Ordered list; mixed types are allowed §5

Frequently Asked Questions

JSON (JavaScript Object Notation) is a lightweight, text-based data-interchange format. Defined in ECMA-404 and RFC 8259, it is the most widely used format for REST API responses and configuration files.
Format (pretty-print) adds indentation and line breaks to make JSON human-readable. Minify removes all unnecessary whitespace to produce the smallest possible payload — ideal for production APIs where every byte counts.
Common reasons: trailing commas after the last key/element, single-quoted strings instead of double quotes, JavaScript-style comments (// or /* */), unquoted keys, or using undefined/NaN/Infinity — which are JavaScript values but not valid JSON.
Absolutely. This tool runs 100% in your browser. No data is transmitted, logged, or stored anywhere. You can safely use it with confidential API payloads and production secrets.
2 spaces is the most common convention (Node.js, most JS style guides). 4 spaces is preferred in Python (PEP 8). Tabs are favoured by some Go and C developers. All produce valid JSON — the choice depends on your team's style guide.
The JSON spec does not forbid duplicate keys, but behaviour is undefined — different parsers may keep the first, last, or all values. In practice, always use unique keys to guarantee consistent results across environments.

Authority Sources & Standards

ECMA-404 — The JSON Data Interchange Syntax (2nd edition, 2017)
ecma-international.org → ECMA-404
RFC 8259 — The JavaScript Object Notation (JSON) Data Interchange Format
rfc-editor.org → RFC 8259
JSON.org — Introducing JSON (Douglas Crockford)
json.org
© 2026 Calci.in · All processing is 100% client-side
Copied!