JSON Diff.

Compare two JSON documents and see exactly what changed — added, removed, and changed values by path. A structural, semantic diff that ignores key order and whitespace. 100% private, in your browser.

No signup · No uploads · No file-size cap

// Paste two JSON documents and press “Compare”.

Compare JSON online - free and private

A JSON diff tool helps you compare two JSON files, API responses, config snapshots, or data exports without noisy formatting changes. Paste both documents above and the JSON compare tool reports real structural differences: added fields, removed fields, and changed values.

How to compare two JSON files in three steps

  1. Paste the original JSON into the left editor.
  2. Paste the JSON to compare on the right — and enable ignore-array-order if your arrays are really unordered sets.
  3. Review and export the added, removed, and changed values by path.

Semantic JSON diff, not line-by-line noise

Unlike a normal text diff, this tool parses the JSON first. That means minified JSON, pretty-printed JSON, and reordered object keys compare correctly. The result is path-based, so you see changes like users[2].email instead of hunting through line numbers.

The difference is easy to see. These two documents are identical data:

{ "name": "Ada", "role": "admin", "active": true }
{
  "active": true,
  "role": "admin",
  "name": "Ada"
}

A line-based diff (git, VS Code, most “compare” sites) reports every line as changed. A structural diff reports no differences, because none exist. That is the whole point — you want to see the one field that actually changed, not 40 lines of reformatting.

When array order matters — and when it does not

By default arrays are compared by position, because in JSON [1, 2] genuinely is not [2, 1] — order is part of the data for things like ranked results or ordered steps. But plenty of arrays are really sets: tags, scopes, permissions, role IDs, feature flags. For those, a reordered list is not a change, and position-based comparison floods you with false diffs.

Turn on ignore-array-order for those cases and the comparison matches items by value instead of index. Most diff tools do not offer the choice and quietly pick one behaviour for you.

What developers use a JSON diff for

Reviewing API changes. Capture a response before and after a deploy and see precisely which fields moved, disappeared, or changed type — the kind of break that slips past a test suite.

Config drift. Compare a staging config against production to find the one flag that explains why they behave differently.

Debugging webhook payloads. Diff a payload that worked against one that failed, and the culprit usually falls straight out.

Test fixtures. When a snapshot test fails, a structural diff tells you whether the data actually changed or just got reserialised.

Why use this JSON compare tool?

It is fast, private, and built for nested JSON, with no file-size cap. That privacy matters more here than on most tools: the JSON you compare is usually a real API response or a production config, and several popular online diff tools default to saving your comparison behind a public share link. Nothing you paste here leaves your browser.

Need to clean the input first? Try JSON repair for broken JSON, JSON formatter to pretty-print, JSON validator to check syntax, or sort JSON keys to normalise both sides before a line-based comparison elsewhere. Reading the result is easier in the JSON viewer. See also our guide on how to compare JSON files.

A structural diff is also the honest way to check a merge. If you combine multiple JSON files into one, diffing the result against the original tells you whether the merge kept what you expected — a shallow merge that quietly dropped a nested block looks fine in the output and obvious in the diff.

FAQ

JSON diff, answered.

How do I compare two JSON files online? +

Paste the first JSON document on the left and the second JSON document on the right, then run the JSON Diff tool. It parses both inputs, compares the data structure, and shows added, removed, and changed values by path. Everything runs in your browser, so your JSON files are not uploaded.

What is the difference between JSON diff and text diff? +

A text diff compares lines, so it can show false changes when JSON is minified, pretty-printed, or reordered. A JSON diff compares parsed values, so whitespace and object key order do not matter. That makes it better for comparing API responses, config files, and nested JSON data.

Can this JSON compare tool ignore key order and whitespace? +

Yes. The comparison is structural and semantic, which means object key order, indentation, and line breaks do not create differences. Only real data changes - added fields, removed fields, and changed values - appear in the result.

How are arrays handled in JSON diff? +

Arrays are compared by position by default because array order matters in JSON. You can use ignore-array-order mode when your arrays behave like unordered sets, such as tags, permissions, scopes, or IDs.

Can I export the JSON diff result? +

Yes. After comparing the two JSON documents, you can export the diff so you can share the change report, attach it to a ticket, or keep it with a release review.

Is my JSON data private? +

Completely. This JSON diff checker is 100% client-side. Your JSON is parsed and compared locally in your browser and is never sent to, stored on, or seen by any server.

Why does my diff show changes when the data looks identical? +

With a text diff, that is usually formatting: one file is minified, or the keys are in a different order, or the indentation differs. None of those are real changes. This tool parses both documents first and compares the values, so identical data reports as identical no matter how it is formatted.

How do I compare two JSON files in VS Code or with git? +

VS Code can diff two open files (right-click a file, Select for Compare, then Compare with Selected), and git diff works on committed JSON — but both are line-based, so reordered keys and reformatting show up as false changes. Normalise first by sorting keys, or use a structural diff like this one.

Can I compare large JSON files? +

Yes. There is no size cap because the comparison runs on your device — the only limit is your browser's memory. Server-based diff tools typically cap uploads around 10 MB, and some default to storing your comparison behind a public share link.

How do I diff two API responses? +

Paste the old response on the left and the new one on the right. Enable ignore-array-order if the API returns collections in a non-deterministic order, which is common for search results and permission lists. The path-addressed output tells you exactly which field changed, so you can attach it to a bug report or a release review.