Σύγκριση JSON / Diff + Patch

Συγκρίνετε δύο έγγραφα JSON σημασιολογικά στο πρόγραμμα περιήγησής σας και μετατρέψτε τη διαφορά σε patch.

Χωρίς μεταφόρτωση, χωρίς επικοινωνία με τον διακομιστή. Μειώστε τον θόρυβο με λειτουργίες σύγκρισης πινάκων, κανόνες διαδρομής και αριθμητική ανοχή.

Επεξεργασία μόνο στο πρόγραμμα περιήγησης, χωρίς μεταφόρτωση σε διακομιστή
Οι λειτουργίες με επίγνωση πινάκων μειώνουν τον θόρυβο κατά τον έλεγχο
Εξαγωγή JSON Patch και JSON Merge Patch
Όλα παραμένουν στη συνεδρία του προγράμματος περιήγησής σας. Τίποτα δεν μεταφορτώνεται.

Recommended workflow

  1. Clean or sort the JSON first with JSON Formatter or JSON Key Sorter when you want consistent input.
  2. Paste or upload the left and right JSON documents, then run Compare.
  3. Choose the array mode, match keys, tolerance, and path rules that fit the review.
  4. Review the summary, changed paths, tree, and exportable patch output.

Δείγμα

This sample shows how reordered arrays, timestamp changes, tiny floating-point differences, and one added item can be narrowed down with match keys, tolerance, and path rules.

Before

Input
{
  "orderId": "A-1001",
  "updatedAt": "2026-04-16T08:00:00Z",
  "customer": {
    "name": "Acme Corp",
    "tags": ["vip", "beta"]
  },
  "items": [
    {
      "sku": "A-1",
      "qty": 2,
      "price": 10
    },
    {
      "sku": "B-2",
      "qty": 1,
      "price": 4.5
    }
  ],
  "summary": {
    "currency": "USD",
    "total": 24.5
  }
}

After

Input
{
  "orderId": "A-1001",
  "updatedAt": "2026-04-16T08:05:00Z",
  "customer": {
    "name": "Acme Corporation",
    "tags": ["beta", "vip"]
  },
  "items": [
    {
      "sku": "B-2",
      "qty": 1,
      "price": 4.5
    },
    {
      "sku": "A-1",
      "qty": 2,
      "price": 10.0001
    },
    {
      "sku": "C-3",
      "qty": 1,
      "price": 7
    }
  ],
  "summary": {
    "currency": "USD",
    "total": 24.5001
  }
}

Τι δείχνει το δείγμα

This sample shows how reordered arrays, timestamp changes, tiny floating-point differences, and one added item can be narrowed down with match keys, tolerance, and path rules.

Πώς να κάνετε σύγκριση

  1. Paste or upload the left and right JSON documents.
  2. Choose strict, ignore order, multiset, or match by key(s), then add any path rules you need.
  3. Run Compare or use the shortcut. Validate first if you only want to check parsing.
  4. Copy or download the changed paths, patch, merge patch, or report when you are done.

What you can do

  • Compare JSON semantically instead of line by line.
  • Match array items by key(s) such as id, sku, or code.
  • Ignore paths, select paths, or apply per-path compare rules.
  • Use numeric tolerance to smooth over tiny floating-point differences.
  • Export JSON Patch, JSON Merge Patch, changed paths, and a Markdown report.
  • Collapse unchanged nodes and jump directly to the relevant path.

Κανόνες σύγκρισης και έξοδος

  • Processing runs entirely in the browser. Nothing is uploaded.
  • Strict, ignore-order, multiset, and match-by-key array modes are supported.
  • Path rules support ignore, strict, ignore-order, multiset, match-keys, and tolerance.
  • Numeric tolerance is applied to numbers only.
  • Comments can be stripped before parse when needed.
  • Large inputs use summary-first rendering and can disable auto-compare.

Συχνές ερωτήσεις

Can I compare arrays of objects by key?

Yes. Use Match by key(s) and list keys such as id or sku. You can also override the rule per path.

How do I ignore timestamps or request IDs?

Add them to Ignore paths, or use a path rule when you want the exception to apply only to one subtree.

Can I keep array order for some parts and ignore it for others?

Yes. Use path rules to set ignore-order, multiset, or match-keys only where you need them.

Does it support JSON with comments?

Standard JSON does not allow comments. Turn on Strip comments before parse only when you need to accept JSONC-style input.

Is anything uploaded to a server?

No. Comparison, normalization, and export all happen locally in your browser.

What can I export?

JSON Patch, JSON Merge Patch, changed paths, and a Markdown report.