How do I format and beautify JSON?

Features & Capabilities

Formatting (also called beautifying or prettifying) makes your JSON human-readable by adding proper indentation and line breaks.

How to Format JSON

  1. 1 Paste your compact or messy JSON into the Input tab
  2. 2 Click the Format button in the toolbar
  3. 3 Switch to the Output tab to see your beautifully formatted JSON

Customization Options

Indentation Settings

You can customize how your JSON is formatted:

  • 2 spaces (default) - Compact and standard
  • 4 spaces - More readable for complex structures

Change this in SettingsIndentation

Before (Compact)

{"name":"John","age":30,"city":"New York","hobbies":["reading","coding"]}

After (Formatted)

{
  "name": "John",
  "age": 30,
  "city": "New York",
  "hobbies": [
    "reading",
    "coding"
  ]
}

Tip: Keyboard Shortcut

Press Option/Alt + Shift + F to format JSON quickly using the editor's keyboard shortcut.

Still Have Questions?

Check out our other FAQ topics or return to the JSON Copilot app

All JSON formatting and validation happens locally in your browser. No data is sent to any servers.