Skip to main content

JSON Diff (Compare)

Compare two JSON objects and list the keys that were added, removed, or changed between them. Paste the second JSON after a line containing only ===

Reviewed for accuracy by the Math Ora X team Last updated

About this tool

Compare two JSON objects and list the keys that were added, removed, or changed between them. Paste the second JSON after a line containing only ===

Example

Input: {"a":1}\n===\n{"a":2,"b":3}

Output: ~ changed: a, + added: b

Privacy

This tool runs entirely in your browser. Your data is processed locally and never uploaded to a server.

How to use this tool

  1. Paste the first JSON object into the input area.
  2. Add a line containing only ===.
  3. Paste the second JSON object below that line.
  4. Run the diff to see which keys were added, removed, or changed.

Step by step, what happens

  1. The tool reads the text above === as the first JSON object and the text below === as the second JSON object.
  2. It parses both inputs as JSON and compares their keys and values.
  3. It marks keys that exist only in the second object as added.
  4. It marks keys that exist only in the first object as removed and keys with different values as changed.

Worked example

Compare an older user profile JSON with a newer one to see what changed.

Input: {"name":"Ava","role":"admin"} === {"name":"Ava","role":"editor","active":true}

  1. The tool reads the first JSON object with name and role.
  2. It reads the second JSON object and sees that active was added and role changed.
  3. It compares the values key by key and lists the differences.

Output: Added: active Removed: none Changed: role

Tips and common mistakes

  • Make sure the separator line contains only ===, with no extra spaces or text.
  • Use valid JSON in both parts, including double quotes around keys and string values.
  • If you compare nested objects, the tool reports differences by keys, so keep the structure consistent between versions.
  • If a key appears in one JSON but not the other, check whether it was really removed or if it was renamed.

Frequently asked questions

How do I enter two JSONs?

Paste the first, a line with only ===, then the second.

Is it a deep diff?

It compares top-level keys and reports added/removed/changed; nested values are compared by their JSON string.

Is data uploaded?

No, comparison is local.

More Developer Tools Tools

Explore related calculators in this category

You Might Also Like

Popular tools from other categories

Can't Find the Right Calculator?

Try our AI Math Solver, type any problem in plain English and get instant step-by-step solutions.

Try AI Solver

Browse All Categories

Home Developer Tools Current Tool
Facebook Twitter WhatsApp