JSON Compare
Compare two JSON documents and see exactly what changed — every added, removed and modified value with its full path. Key order and formatting are ignored, arrays are aligned intelligently, and you can export the changes as a JSON Patch.
| Change | Path | A · Original | B · Changed |
|---|
What Does JSON Compare Do?
It compares the data, not the text — so formatting and key order never cause false differences.
A plain text diff of two JSON files is noisy: re-indenting, reordering keys or minifying make every line look different. This tool parses both documents and compares them structurally, reporting each real difference with its full path, such as $.users[2].email.
Arrays are aligned intelligently: if an item is inserted at the top of a list, you see one added item — not every following element marked as changed.
Comparing API responses or config files across environments? Ignore keys like updatedAt or requestId that always differ, and ignore array order when lists are unordered sets.
The JSON Patch tab gives you the changes as an RFC 6902 patch — a machine-readable list of add, remove and replace operations that transforms A into B, usable with libraries in every language and with HTTP PATCH APIs.
How Differences Are Reported
Every difference is one of three kinds, located by a JSONPath-style path.
Added
A key or array item exists only in B. Patch: {"op": "add", "path": "/users/3", "value": …}
Removed
A key or array item exists only in A. Patch: {"op": "remove", "path": "/legacy"}
Changed
The value differs — including type changes such as "42" → 42. Patch: {"op": "replace", …}
Paths
$.a.b[0] in the table; JSON Pointer /a/b/0 in the patch. Keys with special characters are quoted: $["first name"].
How to Use the JSON Compare
Get your result in under ten seconds.
Paste or drop two documents
Put the original JSON in A and the changed version in B. Files can be dropped onto either side.
Set options
Optionally ignore array order or list keys to skip (comma separated). The comparison updates as you type.
Review or export
Filter added, removed or changed values, click through the paths, or switch to JSON Patch to copy or download the changes.
Why Use the JSON Compare on Developers Web Tools
Fast, accurate and private — built for developers.
Semantic, not textual
Key order, whitespace and number formatting (1.0 vs 1) never show up as differences.
Smart array alignment
Inserted or deleted list items are detected as such instead of shifting every index.
Ignore what doesn't matter
Skip volatile keys like timestamps and IDs, or treat arrays as unordered.
JSON Patch export
An RFC 6902 patch that turns A into B — verified to apply cleanly.
Exact big numbers
64-bit IDs are compared digit-for-digit, never rounded.
Private
Both documents stay in your browser — safe for production data and secrets.
Frequently Asked Questions
No. JSON objects are unordered by definition, so {"a":1,"b":2} and {"b":2,"a":1} are reported as identical. Array order does matter unless you tick Ignore array order.
Items are aligned using a longest-common-subsequence match, like a text diff, so inserting one element is reported as one addition. Items that differ in the same position are compared field by field. Very large arrays (over a few million comparisons) fall back to position-by-position comparison.
JSON Patch (RFC 6902) is a standard format for describing changes to a JSON document as a list of operations: add, remove, replace. Applying the generated patch to A produces exactly B. It's not shown when ignoring array order, because order-free differences can't be expressed as exact positions.
No — they are the same number in JSON. Strings and numbers are different though: "1" vs 1 is reported as a change of type.
Type the key names into Ignore keys, separated by commas — for example updatedAt, etag, requestId. Matching keys are skipped at every level of nesting.
Files up to 50 MB each can be loaded; anything over 512 KB is compared in a background worker so the page stays responsive. The table shows up to 1,000 differences; the counts always include all of them.
No. Both documents are parsed and compared locally in your browser.