View My JSON · diff
JSON Diff Online
A JSON diff is for structural change — renamed keys, missing fields, value swaps — not only a line-by-line text diff.
Two payloads, one real difference
Left:
{ "id": 7, "tags": ["a", "b"], "plan": "free" }
Right:
{ "plan": "pro", "tags": ["b", "a"], "id": 7 }Path diff reports plan as changed (free to pro) and also tags[0] and tags[1], because array positions are compared. The reordered keys id, tags and plan are not reported, and Ignore key order is only needed if you want to be explicit about it.
Why use this
- Path-aware diffs for nested objects
- Red/green text awareness for quick scans
- Validate either side before you trust the diff
When it helps
- Reviewing API contract drift
- Checking a migration changed only expected fields
How to use it
- Open Compare (JSON diff) in View My JSON.
- Paste left (baseline) and right (new) JSON.
- Scan path changes; open either side in Cards if you need context.
Structure first, text second
A line-based text diff compares the characters you typed. A JSON diff compares what the characters mean. That difference matters the moment two files disagree only in whitespace, in key order, or in how a value was written. In the Compare view you get both: a text diff for the raw lines and a path diff that turns each document into a list of paths and values, then reports what was added, removed, changed or left the same. Compare is part of Pro; the other views in the app, and the Format and Validate tools, are free.
How paths are built
Every leaf value gets a path. Object keys are joined with dots, so a value inside user and then address and then city is written as user.address.city. Array positions go in square brackets, so the second item of orders is orders[1]. The path diff matches those strings between the two sides. A path on one side only is added or removed; a path on both sides with different values is changed; an identical value is listed as same, and you can hide those rows to keep the list short.
Key order and array order are not the same
Object members have no defined order in JSON, so { "a": 1, "b": 2 } and { "b": 2, "a": 1 } are the same data, and the path diff pairs them up by path anyway. The text diff, however, will mark them different, which is why it is worth putting the keys in the same order in both documents first if you intend to read the text view. The Ignore key order switch does this for you when you read the path diff.
Arrays are different, because position is part of the value. If a list gains one item at the front, every later path shifts by one, and the diff will report many changed rows even though only one element was inserted. When you see a wall of changes under one array, suspect a shift and look at the first row rather than the last.
Reading the result without being fooled
Decide which document is the baseline before you read a single row, and write it down. The view labels sides left and right, and the added and removed tags are relative to that. Then do a quick sanity check with a tiny pair of documents so you know which way the labels point in your session. Look out for type changes too: 5 and "5" print almost alike and are different values. A key set to null and a key that is missing are also different rows, even if your application treats them the same.
Remember that moved data looks like removal plus addition. The diff has no notion of a renamed key; it only sees one path vanish and another appear.
Making the diff small enough to read
Strip the noise before comparing: timestamps, request IDs and generated tokens change on every call. Compare the slice you care about, such as one record or one config section, rather than a whole export. You can filter rows by path text, copy a summary of the changes, or export them. If both sides must be valid before a path diff is possible, Validate each one first, since a path diff needs two parseable documents.
Your JSON stays in your browser
For core viewing, formatting, and validation, View My JSON parses and renders locally:
- Paste JSON
- Browser parses locally
- Render Cards / Table / Tree locally
- No account required for core tools
FAQ
What is a JSON diff?
A JSON diff highlights structural differences between two documents — added, removed, or changed paths — which is more useful than a plain text diff for nested objects.
Is JSON diff free in View My JSON?
Compare / JSON diff is a Pro feature. Free tools still include viewer, formatter, validator, Cards, Table, and Tree.
Related JSON tools
- JSON ComparatorStaging vs production? Two API responses? Diff JSON path-by-path without juggling formatter tabs.
- Online JSON ViewerRaw braces are hard to read. View My JSON turns JSON into UI so you can understand APIs, configs, and logs faster — one workspace, not five tabs.
- JSON Validator OnlineCheck whether a payload parses before you debug business logic. Fix syntax, then explore structure as UI.
- JSON Editor OnlineA full editor for JSON with format, validate, and visual views beside the text — not a bare notepad.
Guides in this cluster
More guides on the blog · Compare View My JSON with other tools