loot.tools

JSON Diff

Paste two JSON documents side by side and get a clear list of every difference: keys that were added, keys that were removed, and values that changed, each with the path to find it. Unlike a plain text diff, it works on the actual data structure, so reordered keys and different whitespace don't show up as fake changes - only real differences do. Great for comparing API responses, config files, or two versions of the same object. It all runs in your browser, so nothing you paste leaves your machine.

Paste two JSON documents to see exactly what changed between them - added keys, removed keys, and changed values, each with its path. Key order and whitespace don't matter, only the data. Everything runs in your browser.

Original (A)
Changed (B)

Why a structural diff beats a text diff

A text diff treats JSON as lines of characters, so it flags reordered keys, changed indentation, and trailing commas as differences even when the data is identical. This compares the parsed structure instead. It walks both objects key by key and both arrays index by index, so it only reports changes that actually matter to the data. Sort your keys differently or reformat the whitespace and the result stays the same.

How to read the results

Each difference shows the path to the value (like config.theme or items[2]) and what happened to it. Green entries with a plus were added in the changed document. Red entries with a minus were removed. The amber entries with a tilde changed value, showing the old value and the new one. The counts at the top give you a quick sense of how far apart the two documents are.

When this helps

  • Spotting what changed between two API responses while debugging
  • Comparing a config file before and after an edit
  • Checking which fields a new version of an object added or dropped
  • Reviewing a JSON fixture against expected output in a test
  • Confirming two JSON files hold the same data despite different formatting