AzureAzure Kubernetes ServiceContainers

azurerm_kubernetes_cluster cost estimation

A managed Kubernetes cluster on AKS. Control plane is free in Standard tier; you pay for the underlying node VMs and disks.

An azurerm_kubernetes_cluster is a managed Kubernetes cluster. Pricing here is unusually generous in one respect and standard in another.

The control plane has three tiers. Free tier has no SLA and no hourly charge. Standard tier provides an SLA-backed control plane for $0.10/hour ($73/month). Premium tier adds Long-Term Support and is $0.60/hour ($438/month). Most workloads start on Free and graduate to Standard for production.

Worker nodes are regular VMs (azurerm_kubernetes_cluster_node_pool resources). They follow standard VM pricing: hourly rate by VM size, OS disk per GB-month or per tier, and any data disks. A typical 3-node Standard_D4ds_v5 cluster costs ~$420/month for VMs alone.

Three sub-components add cost beyond control plane and VMs:

Azure CNI (the default network plugin) consumes VNet IPs and may require larger subnets, but doesn't have a direct fee. Compare to kubenet which uses NAT.

Load Balancer Standard (default for clusters) is $0.025/hour for the Public IP plus data processing fees per rule. AKS provisions one LB per cluster.

Azure Container Registry (for storing container images) is a separate resource priced per registry tier.

c3x reads the cluster tier and each node pool's VM SKU and count. Storage and bandwidth are computed from the node pools' disk specs.

Terraform example

A minimal but realistic configuration that C3X can estimate.

resource "azurerm_kubernetes_cluster" "main" {
  name                = "production-aks"
  location            = "eastus"
  resource_group_name = azurerm_resource_group.main.name
  dns_prefix          = "production"
  sku_tier            = "Standard"

  default_node_pool {
    name       = "system"
    vm_size    = "Standard_D2ds_v5"
    node_count = 3

    upgrade_settings {
      max_surge = "33%"
    }
  }

  identity {
    type = "SystemAssigned"
  }
}

resource "azurerm_kubernetes_cluster_node_pool" "workloads" {
  name                  = "workloads"
  kubernetes_cluster_id = azurerm_kubernetes_cluster.main.id
  vm_size               = "Standard_D4ds_v5"
  node_count            = 5
  mode                  = "User"
}

Pricing dimensions

What you actually pay for when you provision azurerm_kubernetes_cluster.

DimensionUnitWhat's being charged
Control plane (Free tier)freeNo hourly fee. No SLA. Right for dev/staging clusters.
$0
Control plane (Standard tier)per cluster per hourSLA-backed control plane.
$0.10/hour ≈ $73/month
Control plane (Premium tier)per cluster per hourLong-Term Support, 1.27/1.30+ supported for 2 years.
$0.60/hour ≈ $438/month
Node VMsper VM per hourWorker nodes are regular Azure VMs. Standard VM pricing applies.
Node OS and data disksper GB-month or per tierEach node has an OS disk; pools can attach data disks.
Load Balancerper hour + per GBStandard Load Balancer provisioned by AKS for service-of-type-LoadBalancer.

Optimization tips

Common ways to reduce azurerm_kubernetes_cluster cost without changing the workload.

Use Spot node pools for fault-tolerant workloads

Up to 90% on spot-eligible workloads

Spot VMs in AKS cost up to 90% less. Combine with a separate System pool on regular VMs and a User pool of Spot for batch jobs, CI runners, or stateless workloads.

Start on Free tier for non-production

$73/month per non-prod cluster

Free tier has no SLA but is functionally identical for dev/staging. Only Standard if you need 99.95% SLA on the API server.

Use reserved or savings plans for node VMs

30-60% on VMs

Azure Reserved VM Instances cut node VM costs by 30-60%. Compute Savings Plans are more flexible. For AKS, reserved instances are usually right since nodes are stable.

Use Cluster Autoscaler aggressively in non-production

Workload-dependent

AKS supports min_count and max_count on node pools. Setting min_count = 0 for user pools lets the cluster scale to zero workers between deployments.

FAQ

Is the AKS control plane really free?

The Free tier control plane has no hourly fee. You still pay for node VMs and load balancers. Free tier has no SLA on the API server, which is fine for non-production but a real risk for prod.

How does AKS compare to EKS in cost?

EKS control plane is $73/month minimum (no free tier). AKS Standard is the same price. AKS Free tier is unique to Azure. Node VM pricing is similar across clouds.

Does c3x include the AKS-created load balancer?

Yes. AKS provisions one Standard Load Balancer per cluster. c3x adds its base cost. Service-of-type-LoadBalancer in your manifests creates more rules on the same LB; that's already covered.

What about Virtual Kubelet / ACI integration?

Azure Container Instances (ACI) virtual nodes are billed per pod by vCPU-second and memory-second, similar to AWS Fargate. c3x estimates ACI separately when declared in Terraform.

Related resources

Estimate this resource in your own Terraform

Free, open source, no API key. C3X parses your Terraform and shows line-item cost for every resource, including azurerm_kubernetes_cluster.