ToolTunnel

Kubernetes Resource Diff

Compare Kubernetes YAML manifests and identify added, removed, and modified resources and configuration fields between two versions.

Compare Kubernetes Manifests

Compare two Kubernetes YAML manifests and identify added, removed, and changed resources with exact value transitions.

21 lines
21 lines

Diff Summary

Resource-level changes between the two manifests.

AddedAdded
0
Resources only in the new manifest
ChangedChanged
1
Resources with field-level differences
RemovedRemoved
0
Resources only in the old manifest
UnchangedChange
0
Resources with no detected changes

Resource Changes

Detailed comparison for each Kubernetes resource.

1 total resources
Deployment/default/nginx
Before document #1 · After document #1
Changed
Changed fields
spec.replicas
Before
2
After
5
spec.template.spec.containers[0].image
Before
nginx:1.25
After
nginx:1.27
Full resource — Before
{
  "apiVersion": "apps/v1",
  "kind": "Deployment",
  "metadata": {
    "name": "nginx",
    "namespace": "default"
  },
  "spec": {
    "replicas": 2,
    "selector": {
      "matchLabels": {
        "app": "nginx"
      }
    },
    "template": {
      "metadata": {
        "labels": {
          "app": "nginx"
        }
      },
      "spec": {
        "containers": [
          {
            "name": "nginx",
            "image": "nginx:1.25",
            "ports": [
              {
                "containerPort": 80
              }
            ]
          }
        ]
      }
    }
  }
}
Full resource — After
{
  "apiVersion": "apps/v1",
  "kind": "Deployment",
  "metadata": {
    "name": "nginx",
    "namespace": "default"
  },
  "spec": {
    "replicas": 5,
    "selector": {
      "matchLabels": {
        "app": "nginx"
      }
    },
    "template": {
      "metadata": {
        "labels": {
          "app": "nginx"
        }
      },
      "spec": {
        "containers": [
          {
            "name": "nginx",
            "image": "nginx:1.27",
            "ports": [
              {
                "containerPort": 80
              }
            ]
          }
        ]
      }
    }
  }
}

How resource matching works

Resources are matched using their Kubernetes kind, namespace, and metadata name.

For example, Deployment/default/nginx represents the Deployment named nginx in the default namespace.

Field changes show both the previous and new values, making changes such as spec.replicas: 2 → 5 immediately visible.

YAML parsing errors display the exact line and column when available, and the corresponding line number is highlighted in the editor.

The comparison is performed locally in your browser. The YAML is not sent to a backend by this tool.