Comparador JSON / diff + parche

Compara dos documentos JSON de forma semántica en tu navegador y convierte el diff en un parche.

Sin subida ni ida y vuelta al servidor. Reduce el ruido con modos de comparación, reglas por ruta y tolerancia numérica.

Procesamiento solo en el navegador, sin subida al servidor
Los modos con conciencia de arrays reducen el ruido de revisión
Exporta JSON Patch y JSON Merge Patch
Todo permanece en tu sesión del navegador. Nada se sube.

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.

Ejemplo

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
  }
}

Qué muestra el ejemplo

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.

Cómo comparar

  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.

Reglas de comparación y salida

  • 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.

Preguntas frecuentes

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.