Free private JSON formatter and validator

Clean up JSON.
Find the broken spot.

Paste JSON or open a .json file. Make it readable, find syntax errors, sort object keys, create a compact copy, or explore the data as a tree.

Your JSON stays private. It is processed entirely in this browser tab. It is not uploaded, logged, or sent to an API.

01

Paste or open your JSON

Then choose Format, Compact, Sort, or Tree view. Your JSON itself is never saved.

Open a .json file
Or paste JSON directly into the left editor.

JSON to check

You can edit this

Clean result

Items found0
Nested levels0
Result size0 B
Top level-

What each choice does

Four useful ways to handle JSON.

01

Format and check

Adds readable indentation and tells you where invalid JSON is probably broken.

02

Compact or sort

Compact removes unnecessary spaces. Sort puts object keys in A–Z order while leaving array order alone.

03

Open Tree view

Browse nested objects and arrays by opening and closing sections instead of reading one long block of text.

Straight answers

JSON questions.

What is JSON?

JSON is a plain-text format used by websites, apps, APIs, and configuration files to store structured data such as names, settings, lists, and values.

Does sorting keys change the meaning of JSON?

Object key order should not carry meaning in JSON. Arrays can depend on order, so this tool never rearranges array items.

Why does valid JavaScript sometimes fail as JSON?

JSON requires double-quoted property names and strings. It does not allow comments, trailing commas, undefined, functions, NaN, or Infinity.

Can I safely paste private API data here?

The formatter does not transmit the text. You should still remove passwords, API keys, and other secrets before sharing the formatted result with someone else.