Skip to main content
KalkuNet

JSON Diff — Compare Two JSON Documents, Ignoring Key Order

Normalize key order and spot added, removed or modified JSON paths clearly.

Runs in your browserDeveloper · JSON, YAML, TOML, XML & CSV Converters

2 added · 1 removed · 3 changed

~ $.version: "2.4.1" → "2.5.0"
~ $.port: 8080 → "8080"
+ $.tags[2]: "eu"
~ $.owner.email: "[email protected]" → "[email protected]"
- $.debug: true
+ $.timeoutMs: 3000
  • Key order is ignored, numbers are compared by exact decimal value (1, 1.0 and 1e0 are equal; big numbers are not rounded), arrays are compared by index.

When to use the Semantic JSON Object Diff Checker

  • Meaning, not text

    Two JSON documents are compared as data. Key order, spaces and indentation are ignored, so a file that was only re-formatted shows no false differences as a plain text diff would.

  • Numbers compared by value

    1, 1.0 and 1e0 count as equal, while two 19-digit IDs that differ in the last digit are still reported, because numbers are compared as exact decimals without rounding.

  • Every change with its path

    The result lists keys added (+), removed (-) and changed (~) with paths such as $.owner.email and the old and new values. Type changes, such as the number 8080 becoming the string "8080", are flagged too.

  • For config and API reviews

    Useful for comparing API responses before and after a deploy, package.json files, or configs between environments such as staging and production.

Frequently asked questions

What if there are duplicate keys?

The last value is used, as JSON.parse and Python do.

Is the string "1" equal to the number 1?

No. Different types are always reported as a change, because many API bugs come from numbers turning into strings.

Can it compare large files?

Yes, a few megabytes per side usually finish within seconds in a modern browser.

Are both documents uploaded?

No. The comparison runs in your browser.

How do I read the result?

Each line starts with + for a key or item only in JSON B, - for one only in JSON A and ~ for a changed value, followed by the path and the value as compact JSON.

Learn more