CF
ClickyFix
Contact
ClickyFixDeveloper ToolsJSON Formatter

JSON Formatter & Validator

Beautify · Minify · Validate · Syntax highlighting · Key/object/array stats · Free · Runs in browser

Indent:

JSON Syntax Quick Reference

TypeSyntaxExample
String"key": "value""name": "ClickyFix"
Number"key": 123"count": 42
Boolean"key": true / false"active": true
Null"key": null"middleName": null
Array"key": [item1, item2]"tags": ["free", "tool"]
Object"key": { "nested": "value" }"meta": {"v": 1}

Common JSON Errors

Trailing comma

{"name": "Alice",}

Remove the comma after the last item in objects and arrays — JSON does not allow trailing commas.

Single quotes

{'name': 'Alice'}

JSON requires double quotes for strings and keys. Single quotes are not valid JSON.

Unquoted keys

{name: "Alice"}

Object keys must be quoted strings in JSON. Use double quotes around all keys.

Comments

{"name": "Alice" // comment}

JSON does not support comments. Remove all // and /* */ comments before parsing.

Undefined / NaN / Infinity

{"value": undefined}

JSON only supports null, not undefined, NaN, or Infinity. Replace these with null or remove the key.

Frequently Asked Questions

Is my JSON sent to a server?

No. Formatting and validation runs entirely in your browser using JavaScript's built-in JSON.parse() and JSON.stringify(). Your data never leaves your device.

What is the difference between Format and Minify?

Format (beautify) adds indentation and line breaks to make JSON human-readable. Minify removes all whitespace to produce the smallest possible string, which is what you'd send over an API. Both represent exactly the same data structure.

Why is 2 spaces better than 4 spaces for JSON?

2 spaces is more compact — deeply nested JSON stays readable within a typical editor or terminal width. Many style guides (including Google's and Airbnb's) use 2 spaces. 4 spaces is common in Windows-oriented tooling. The choice is purely aesthetic.

Can I use this to format JSON from an API response?

Yes — copy the raw JSON from your browser's network tab, Postman, curl output, or any other source, paste it here, and click Format. The key/object/array stats are also useful for quickly understanding an unfamiliar API response structure.