JSON
JSON Diff
Find structural and value differences between JSON documents.
JSON Diff workspace
Input
Preparing tool…
Result
Preparing tool…
How it works
Documentation
About JSON Diff
Compare two strict JSON documents structurally and inspect added, removed, and changed values. The comparison runs entirely in your browser.
How to compare JSON
Enter the earlier document under Original JSON, enter the new document under Modified JSON, then choose Compare JSON. The result is a JSON array of semantic differences.
Structural vs text comparison
JSON Diff compares parsed JSON values, not source text. Whitespace, indentation, escaped-equivalent strings, equivalent number spellings, and object property order do not count as changes.
Object key ordering
Objects are compared by member name regardless of the order in which properties appear. Results traverse object keys in a stable order so semantically identical inputs always produce the same diff ordering.
Array comparison
Arrays are compared by index in the current version. Item moves or insertions are not detected semantically as moves, so an insertion near the beginning can produce several index changes and a trailing addition or removal.
Added, removed and changed values
An added entry contains the new value, a removed entry contains the original value, and a changed entry contains both. A whole added or removed subtree and a value-type replacement each count as one difference at that path.
JSON Pointer paths
Each path uses RFC 6901 JSON Pointer syntax, such as /users/0/name. The root pointer is the empty string. In member names, ~ becomes ~0 and / becomes ~1.
Valid JSON requirements
Both inputs must be strict JSON. Objects, arrays, strings, numbers, booleans, and null are accepted as roots. Comments, trailing commas, empty input, JSONC, and JSON5 are rejected.
Result limits
Original and Modified JSON are each limited to 2 MiB measured as UTF-8. SyntaxDock counts every structural difference and displays the first 1,000 entries; when the display is truncated, the total and displayed counts remain explicit.
Privacy
Your Original JSON, Modified JSON, diff values, and JSON Pointer paths are processed locally in this browser. SyntaxDock does not upload or store them.
FAQ
Why are reordered properties unchanged? JSON objects are unordered collections of named members. Does this detect moved array items? No. Arrays are compared by index without move detection or sequence alignment.
Related tools
Use JSONPath Tester to select values from a JSON document. Related conversion tools are listed below.