SparkJSONJSON Compare / Diff Online

JSON Compare / Diff Online

Paste left and right JSON to list every path that was added, removed, or changed. SparkJSON deep-compares after both sides parse — whitespace and key order in objects do not create false diffs.

Free SparkJSON tool — runs 100% in your browser. No signup, no upload, no paywall. This page compares two JSON documents locally.

Loading compare…

No data leaves your browser.

Advertisement

What a JSON diff actually reports

A structural JSON compare walks both trees recursively. Object keys are matched by name (order does not matter). Array items are matched by index, so reordering an array shows up as changes at those positions.

If either side is invalid JSON, you get a parse error first. That prevents a misleading partial diff when the document never parsed successfully.

  • Path-level — see exact dotted paths like meta.active or roles[1].
  • Parse-first — syntax errors block the diff until both sides are valid.
  • Private — comparison never leaves your browser.

Diff pitfalls that confuse people

Key order looks different but isn’t

Pretty-printing may reorder keys visually. Object key order is not a semantic difference in JSON compare.

{ "b": 1, "a": 2 }  ≈  { "a": 2, "b": 1 }

Array reorder counts as change

Moving an item from index 0 to index 1 changes both paths. Sort arrays first if order is irrelevant to you.

Number vs string

"1" and 1 are different values. Normalize types before comparing configs.

Frequently asked questions

Can I compare minified and formatted JSON?

Yes. After parse, whitespace is irrelevant. Only structure and values are compared.

Does SparkJSON upload either document?

No. Diffing runs entirely in your browser with no upload endpoint.

Where is the full tool page?

The same compare UI lives at /tools/json-compare/ with related-tool links and FAQ schema.