JSON Diff Checker

Paste an original and a changed JSON document and see exactly what is different: keys that were added, keys that were removed and values that changed, each with its path. The order of keys is ignored, because two objects with the same keys in a different order hold the same data. Use it to compare two API responses, two config files or two versions of a data file.

What you enter

What you get

How it works

  1. Paste the original JSON in the first box and the changed JSON in the second. Both must be valid JSON.
  2. Choose how to compare arrays. 'By position' compares item 1 with item 1, item 2 with item 2. 'Ignore order' treats an array as a bag of items, so a reshuffled list shows no difference.
  3. Read the counts, then the table: each row is one difference with its path, the old value and the new value.
  4. Fix the data or the code that produced it, then paste again to confirm the two documents match.

Why a plain text diff is the wrong tool for JSON

A text diff compares lines. Two servers can send the same data with keys in a different order, different spacing or a different line layout, and a text diff will mark almost every line as changed. A structural diff first reads the data and then compares meaning, so only real differences remain.

That is also why the paths matter. A line number tells you little when the whole document is on one line, but a path such as $.settings.notifications.email points straight at the field you need to look at, in the same notation you would use to read it in code.

Common reasons two responses differ

The usual suspects are values that change on every request, such as timestamps, request ids and tokens, and optional fields that are missing in one environment. When you compare a staging response with a production one, expect those and look for the rows that are not noise.

The second group is type drift. A field that is a number in one response and text in another, or a single object that becomes a list of one, breaks the code that reads it without changing how the data looks. Rows where the before and after values print the same except for quotes are worth a close look.

Tips

Frequently asked questions

Does the order of keys matter?

No. Keys are compared by name, so {"a":1,"b":2} and {"b":2,"a":1} are reported as identical. Only the order of items inside arrays can matter, and you choose whether it does.

How does 'Ignore order' work for arrays?

Each item is turned into a canonical form with its keys sorted, then the two lists are matched item by item, one match per item. Items left over on the left are reported as removed and items left over on the right as added. Duplicates are counted, so two copies of an item must appear on both sides to match.

What counts as a change?

A change is a value at the same path that differs between the two documents, including a different type such as a number that became text, or null that became an object. Added and removed are keys or array items that exist on only one side.

Is my data uploaded?

No. Both documents are parsed and compared in your browser. Nothing is sent to a server.

Why do very large numbers compare oddly?

JSON numbers are read as ordinary floating-point values, so whole numbers above about 9 quadrillion lose exact precision before they are compared. Keep long identifiers as text in quotes if they must stay exact.

Related: JSON formatter and validator, JSON to CSV converter, HTML table generator.

Start for free or see all free tools. We.Inc is free to start, with no card needed. AI building is on paid plans from $20 a month.

More in Free Tools

We.Inc is an AI-powered website builder you can resell under your own brand. Launch a branded client dashboard, bill on Stripe Connect, and deliver AI-generated websites in minutes. White-label plans start at $99 a month for 25 client sites, with a 7-day free trial and no per-site fees.

Product

Who It's For

Features

Resources

Company

View Sitemap