About the JSON Structural Diff
Comparing two JSON documents as plain text is misleading — reordering keys or reformatting whitespace can make a line-based diff show changes that don't actually matter, while missing real changes buried in reformatted lines.
This tool compares two JSON documents structurally — by their actual keys and values — so you see only the additions, removals, and value changes that matter, regardless of formatting or key order.
How it works
- Paste the original JSON into the left box and the updated JSON into the right box.
- Click Compare to see a structural diff listing every added, removed, or changed field.
- Use the result to understand exactly what data changed between two API responses, config versions, or test fixtures.
Common use cases
- Comparing API responses across versions: Diffing a JSON response from an old API version against a new one to see exactly which fields were added, removed, or changed in value.
- Reviewing config or fixture changes: Comparing two versions of a JSON test fixture to confirm only the intended fields were modified before committing.
- Debugging unexpected state changes: Comparing a JSON object's state before and after an operation to pinpoint exactly which properties an operation actually mutated.
Frequently asked questions
How is this different from a plain text diff on JSON?
A structural diff parses both documents and compares them by key and value, so reordered keys or different indentation don't produce false differences — only genuinely different or missing/added fields are reported.
What do 'added', 'removed', and 'changed' mean in the result?
'Added' means a key exists in the modified JSON but not the original; 'removed' means the reverse; 'changed' means the key exists in both but its value is different.
Does this work with deeply nested objects and arrays?
Yes — the comparison recurses into nested objects and arrays, reporting differences at whatever depth they actually occur, with a path showing exactly where in the structure the difference is.
Why did I get an 'Invalid JSON' error?
One or both of the documents you pasted isn't valid JSON — check for the same common issues as any JSON error, like trailing commas, unquoted keys, or mismatched brackets, before comparing again.
This tool runs entirely in your browser — nothing you enter is sent to a server. Read more in the Privacy Policy, or browse the full list of tools.