Diff Knowledge Base

JSON Compare Tool: Find Differences Between Two JSON Objects

Compare two JSON objects or files side by side. Highlights added, removed, and changed fields with colour coding. Free JSON comparison tool, browser-only.

Why Compare JSON Objects?

JSON comparison is a critical workflow in API development, DevOps, and data engineering. Common use cases include detecting configuration drift, verifying API response changes across versions, reviewing data pipeline output, and validating test fixtures.

What the JSON Comparison Highlights

  • Added: Keys present in the right/new version but not in the left/old version
  • Removed: Keys present in the left/old version but missing from the right/new version
  • Changed: Same key, different value between versions
  • Unchanged: Identical key-value pairs shown in neutral colour

JSON Comparison vs Text Diff

A plain text diff (like git diff) compares JSON line-by-line. If a developer reformatted the JSON (changed indentation), a text diff shows hundreds of false changes. A semantic JSON diff compares the actual data structure, ignoring whitespace, so only real data changes are shown.

Use Cases

  • Comparing Terraform state files before/after plan
  • Verifying Kubernetes manifest changes between environments
  • API versioning: v1 response vs v2 response
  • Database migration: before/after document comparison
json
// Left JSON (version 1)
{
  "name": "Widget A",
  "price": 29.99,
  "sku": "WGT-001",
  "active": true
}

// Right JSON (version 2)
{
  "name": "Widget A",
  "price": 34.99,    // 🟡 Changed
  "sku": "WGT-001",
  "active": true,
  "stock": 150       // 🟢 Added
}
// Summary: 1 field changed (price), 1 field added (stock)

Try the free JSON Diff

Runs entirely in your browser — no upload, no signup, and your data never leaves your device.

Open JSON Diff

Frequently Asked Questions

Is JSON Compare the same as JSON Diff?

Yes. "JSON Compare", "JSON Diff", and "JSON Comparison" all refer to the same operation: finding the structural differences between two JSON documents.

Does JSON comparison ignore whitespace?

Yes. Our semantic JSON diff compares data structure and values, completely ignoring whitespace, indentation, and key ordering differences.

Can I compare JSON files larger than 1 MB?

Yes. Comparison is a structural walk of both trees rather than a line-by-line text diff, and it runs locally — the practical ceiling is your device memory, not a server limit.

How does the tool handle array comparison?

Arrays are compared positionally by default (index 0 vs index 0). A key-based array comparison is planned for future releases.

Tools mentioned in this guide

Related JSON Topics & Reference Articles