JSON Diff

Compare two JSON documents side-by-side with semantic or text diffing. Runs entirely in your browser.

Compare two JSON documents

Paste original and modified JSON above, then press Compare.

About JSON Diff

Paste two JSON documents to compare them line-by-line. In semantic mode, keys are sorted and formatting is normalized before diffing — so only meaningful data changes are highlighted. Switch to text mode for a raw character-level comparison. Split and unified views available.

Features

  • Semantic diff: normalize and sort keys before comparing
  • Text diff: compare raw JSON as plain text
  • Split-view with side-by-side line numbers
  • Unified view with addition/deletion markers
  • Stats showing added, removed, and unchanged lines
  • Swap, paste, and sample data for quick testing
  • 100% client-side — nothing is uploaded

How to use

  1. 1Paste original JSON on the left and modified JSON on the right.
  2. 2Choose Semantic or Text diff mode.
  3. 3Click Compare to generate the diff.
  4. 4Toggle Split or Unified view to inspect changes.

Frequently Asked Questions

What is semantic diff mode?
Semantic mode parses both inputs, sorts object keys alphabetically, and formats with consistent indentation before diffing. This ensures only actual data changes are shown, ignoring key order and whitespace differences.
What if my JSON is invalid?
In semantic mode, invalid JSON produces an error indicating which side has the problem. In text mode, any text is compared as-is without parsing.
Does it handle large JSON files?
Yes. The diff algorithm supports documents up to 5,000 lines per side. All processing runs locally in your browser.
Is my data sent to a server?
No. All comparison runs entirely in your browser. Nothing is uploaded or stored.

Related Utilities

Explore other tools