Compare the structure and values of two JSON documents to find additions, removals, value changes, and type changes. Every difference is associated with a path and before-and-after values.
Comparison parses both documents first. Object member order is treated as insignificant, while array position is significant unless you explicitly choose to ignore array order.
How structural comparison differs from a text diff
A line diff reports whitespace, indentation, and key-order changes even when two JSON objects represent the same data. Structural comparison operates on parsed values, so it focuses on properties, types, array items, and primitive values.
A changed value and a changed type are reported separately. For example, the number 42 and the string "42" may look similar in a log but are different JSON types and can behave differently in an application.
Understanding array order
Arrays are ordered by definition, so moving an item can change meaning. Ignoring array order is useful for set-like lists, but it can conceal meaningful sequence changes and becomes ambiguous when duplicate items are present. Enable it only when the producing system treats the array as unordered.
Practical uses for a JSON diff
Compare an API response before and after a deployment, inspect configuration drift between environments, review a webhook version change, or verify that a transformation changed only expected paths. Keep secrets out of screenshots and shared reports even though processing is local.
Frequently asked questions
Does object key order create a difference?
No. JSON object member order is not treated as a data change.
Are arrays compared in order?
Yes by default. You can opt to ignore order when the array is genuinely set-like.