ArgoCD › Applications

What are ignoreDifferences and why are they needed?

Intermediate

Answer

ignoreDifferences tells ArgoCD to disregard specified fields when computing diffs, so the app doesn't show OutOfSync due to values mutated by controllers (e.g., replica counts set by HPA, or webhook-injected fields). You target fields by group/kind and JSON pointers or jq/JSONPath, preventing false drift and sync fights.
spec:
  ignoreDifferences:
    - group: apps
      kind: Deployment
      jsonPointers:
        - /spec/replicas   # managed by HPA
Real-world example With HPA controlling replicas, ArgoCD ignores /spec/replicas so it doesn't constantly report drift or reset the count.

Common follow-ups: Why does HPA cause drift? | How do you target fields to ignore?