toolqik

122 · JSON

JSON Diff Checker

Compare two JSON documents: every added, removed and changed value, plus a JSON Patch.

Runs in your browser
Compare arrays

    About this tool

    A text diff of two JSON files is noisy: reordered keys, different indentation and a moved line all show up as changes even when the data is the same. This JSON diff tool compares the data. It parses both documents, ignores key order and whitespace, and lists every value that was added, removed or changed, with its exact path.

    How to compare JSON

    1. Paste the original JSON on the left and the changed version on the right (or drop a file on each box).
    2. The comparison runs as you type. The summary shows how many values changed, were added and were removed.
    3. Changes lists each difference with its path, such as $.items[0].qty, and the old and new values.
    4. Side by side shows both documents normalized (keys sorted, same indentation) with changed lines highlighted and unchanged stretches collapsed.
    5. JSON Patch gives an RFC 6902 patch that turns the left document into the right one.

    Comparing arrays

    Arrays are where JSON diffs get tricky. Pick the rule that matches your data:

    • By position: item 0 is compared with item 0, and so on. Right for ordered data such as steps or coordinates.
    • Ignore order: treats arrays as sets, so ["a","b"] and ["b","a"] are equal. Right for tags, permissions and IDs.
    • Match by key: pairs objects that share a key (usually id) and compares them field by field. Right for lists of records, where inserting one record would otherwise make every later item look changed.

    What a JSON Patch is

    JSON Patch (RFC 6902) is a standard format for describing changes: a list of operations like {"op": "replace", "path": "/status", "value": "paid"}. Paths use JSON Pointer syntax, where /items/0/qty means items → first item → qty. Libraries such as fast-json-patch (JavaScript) and jsonpatch (Python) apply patches, and HTTP APIs accept them with PATCH requests and the application/json-patch+json content type.

    Common uses

    • Compare API responses between staging and production, or before and after a deploy.
    • Review changes to config files, feature flags and translations.
    • Check what a migration or a script actually changed in exported data.

    To combine documents instead of comparing them, use JSON merge.

    FAQ

    How do I compare two JSON files?

    Paste or drop one file on the left and the other on the right. Every added, removed and changed value is listed with its path, and a side-by-side view highlights the changed lines.

    Does key order matter when comparing JSON?

    No. JSON objects are unordered, so {"a":1,"b":2} and {"b":2,"a":1} are reported as identical. Whitespace and indentation are ignored too.

    How do I compare JSON arrays when the order is different?

    Choose “Ignore order” to treat arrays as sets, or “Match by key” to pair objects by a field such as id. By default arrays are compared item by item.

    What is a JSON Patch?

    A standard (RFC 6902) list of operations that turns one JSON document into another, such as add, remove and replace at JSON Pointer paths. The JSON Patch tab gives the patch from left to right.

    Can I compare large JSON files?

    Yes. The structural comparison handles large documents; the side-by-side line view is skipped for very large or very different files.

    Is my JSON uploaded?

    No. Both documents are compared in your browser.

    esc
    ↑↓ navigate↵ open