JSON Beautifier

Compare JSON Online: JSON Diff Tool

Paste two JSON objects, arrays or files to compare them side by side. Differences are listed by key path. Free, private and instant.

Left JSON
Right JSON

Keys are matched by name. Arrays are compared by index unless you ignore their order; unordered arrays retain duplicate counts and are reported as a whole when changed. Paths use JSON Pointer: ~1 represents / and ~0 represents ~.

Compare JSON values by their structure

A structural comparison matches object keys regardless of their order and reports added, removed or changed values at JSON Pointer paths. Formatting differences alone do not count as changes.

1

Paste or upload the original and updated documents.

2

Decide whether array order matters for your data.

3

Review the changed paths and the values on each side.

Before

{"user":{"name":"Alice","active":true},"roles":["editor"]}

After

/user/active — changed: true → false
/roles/1 — added: "admin"
  • Objects with the same values compare equal even when key order changes. Arrays use indexes by default.
  • Ignoring array order compares arrays as multisets, preserving duplicate counts. A changed unordered array is reported as one changed value.
  • JavaScript numeric precision applies to parsed inputs. JSON Pointer uses ~1 for a slash in a key and ~0 for a tilde.

Need to read or debug JSON from this result? Paste it into the JSON beautifier to format, validate and explore it as a tree.

Frequently Asked Questions

How does the JSON Diff tool work?

Both inputs are parsed and compared by structure. The result lists added, removed, and changed values with JSON Pointer paths. Object key order is ignored; array order is significant unless you enable Ignore array order.

Does key order affect the diff?

No. Objects with the same keys and values compare equal regardless of key order. Arrays are compared by position by default. Enable Ignore array order to compare arrays as multisets, including duplicate counts.

Does it handle deeply nested JSON?

Yes. Both objects are fully parsed before comparison, so nested changes are identified by their paths. Browser memory and stack limits still apply to unusually deep documents.

Read the guide: How to Compare JSON →Want a consistently ordered export: Sort JSON →Check inputs: Validate JSON →

People Also Ask

How do I compare two JSON files online for free?

Open the JSON Diff tool, paste the first file's contents into the left panel and the second into the right panel. The comparison runs instantly in your browser — no upload, no sign-up, and no file size limit beyond what your browser can hold.

Can I compare JSON arrays, not just objects?

Yes. Paste a JSON array on each side and the tool diffs it the same way as an object — element by element, by keys and paths. Reordering array items counts as a change by default. Enable Ignore array order when order is irrelevant.

What's the difference between JSON diff and deep equal?

Deep equal returns a single true/false answer — it tells you the objects aren't identical but not why. JSON diff shows exactly which paths changed, what was added, and what was removed, which is what you actually need when debugging an API response or a config change.

Is my JSON data uploaded anywhere when I use this tool?

No. Both JSON inputs are parsed and compared entirely client-side, in your browser. Nothing is sent to a server, which makes it safe to paste in JSON containing sensitive data like API responses or internal config.

Can I diff a large JSON file?

Yes, though very large files (several megabytes) may take a moment to parse and render since the comparison runs in the browser rather than on a server. For typical API responses and config files, the diff is instant.