Kubernetes Cost Optimization: 8 Levers That Actually Move the Bill

By Stackvora Team · 2026-05-14 · 11 min read

Most Kubernetes bills are 40–60% overprovisioned. The good news: you rarely need heroics to fix it. Eight levers, in order of impact:

1. Right-size requests (biggest lever, always)

CPU and memory requests — not limits — drive scheduling and node count. If your requests are 2× your real usage, you're paying for 2× the cluster.

Use the Vertical Pod Autoscaler (VPA) in recommendation mode, or Goldilocks, to get honest numbers. Then update the manifest, don't leave VPA in auto-mode for production.

2. Turn on Karpenter (or Cluster Autoscaler with node groups)

Fixed-size node pools waste money. Karpenter provisions the cheapest node that fits your pending pods and consolidates aggressively. On AWS, EKS + Karpenter typically saves 30–50% versus a static node group.

3. Use spot / preemptible for the right workloads

Batch, CI, staging, stateless web tiers — all fine on spot. Databases, stateful sets, single-replica critical services — leave on on-demand.

Rule of thumb: if it survives a 2-minute eviction notice, it's a spot candidate.

4. Kill zombie namespaces

Every long-lived cluster has 5–20 dead namespaces from old features, PoCs, and departed teams. A quick audit:

kubectl get ns -o json | jq -r '.items[] | select(.metadata.creationTimestamp < "2025-01-01") | .metadata.name'

5. Compact your logging

Log volume is often the #2 line item after compute. Sample verbose logs, drop debug in production, and use a tiered log backend (hot 7d, cold 90d).

6. Delete unused PVs

Storage is silent money. Persistent volumes hanging around after PVC deletion (Retain policy) accumulate for years.

7. Consolidate load balancers

Each LoadBalancer service = one cloud LB = $18–25/month. Use an ingress controller (nginx, Traefik, ALB Controller with target groups) and share one LB across many services.

8. Match instance family to workload

Memory-heavy workloads on general-purpose nodes waste CPU. CPU-heavy workloads on memory-optimized nodes waste RAM. Karpenter can pick per pod — configure the NodePool with the right requirements.

Measuring the impact

Install OpenCost or Kubecost before you start optimizing. You need the baseline to prove the savings, and to catch regressions when a new team ships a hot workload.

The cheapest cluster is the one where every workload has honest requests and zero idle nodes. Everything else is optimization theater.

More blog posts · Knowledge base