← Back to tool

Compare · Keys · Values

JSON Diff Checker

Updated: June 2026

Two API responses, two config files, two snapshots of the same object — and a behaviour that changed between them. A JSON diff checker shows you which key gained a value, which field was removed and which number was edited, so you stop guessing and see the change directly.

Compare JSON →

Free · No upload · Line & character level

Format both sides first

This is a text-based diff, which means it compares line by line. JSON that arrives as a single minified line will diff poorly, because the whole document is one line. The trick is to pretty-print both versions with the same indentation before comparing, so each key sits on its own line:

{
  "id": 42,
  "active": true,
  "price": 9.99
}

Once both sides are formatted identically, the diff becomes beautifully readable: a changed value shows as one red line and one green line, an added key appears as a single green line, and a removed key as a single red line. Our JSON Formatter will pretty-print and sort both documents in one click.

Sort keys to compare by content

JSON objects have no guaranteed key order, so two objects that are semantically identical can list their keys differently. A line diff treats that as a change. The fix is to sort keys alphabetically on both sides before diffing — then only genuine content differences remain. Sorting also stabilises the output so re-running the comparison always lines up the same way.

If you would rather not reorder, you can lean on the ignore options instead, but sorting first gives the cleanest, most trustworthy JSON diff.

What the diff reveals

Change in the dataHow it appears
A value was editedOld line in red, new line in green, changed characters marked
A key was addedA single green line
A key was removedA single red line
An array element changedThe element's line highlighted in place

Use character granularity to pinpoint a one-digit difference in an id or a flipped boolean, and read the similarity percentage to gauge how much the two payloads diverge overall.

Private and offline-friendly

API payloads frequently contain tokens, customer records and internal identifiers, so pasting them into a server-side comparator is risky. This checker keeps everything local: the comparison runs in your browser and nothing is uploaded. You can compare production data, webhook bodies and secrets safely, and the page keeps working with no connection once it has loaded.

Frequently asked questions

How do I compare two JSON objects?

Format both JSON documents with the same indentation, paste them into the two panels, and the tool highlights every line that differs, including changed values and added or removed keys.

Why should I format the JSON first?

A text diff compares lines, so pretty-printing both sides with the same indentation puts each key on its own line and produces a clean, readable difference. Sorting keys first makes it even tidier.

Does key order matter?

For a line-based diff, yes. If two objects have the same keys in a different order they will show as changed, so sort the keys on both sides first to compare by content.