Why do idle ALBs cost so much? How ALB and LCU pricing works
An Application Load Balancer is billed on two meters. The first is a fixed hourly charge that runs for every hour the ALB exists, whether or not it carries traffic. The second is LCU-hours (Load Balancer Capacity Units), which scale with usage. Each hour, AWS measures four dimensions and bills only the highest one:
- New connections per second
- Active connections per minute
- Processed bytes (GB per hour)
- Rule evaluations per second
A near-idle ALB uses almost no LCUs, but it still pays the full hourly charge. When every service gets its own ALB, that fixed charge is multiplied by the number of services.
Illustrative estimate (assumed numbers, not a benchmark)
Assumed inputs: N = 20 services, 730 hours/month, hourly charge H = $0.02, LCU price L = $0.01, and each service averaging 0.1 LCU.
Formula: monthly = (ALBs × 730 × H) + (total LCU × 730 × L)
| Setup | Hourly charges | LCU charges | Total |
|---|---|---|---|
| 20 per-service ALBs | 20 × 730 × 0.02 = $292.00 | 2.0 × 730 × 0.01 = $14.60 | $306.60 |
| 1 shared ALB | 1 × 730 × 0.02 = $14.60 | 2.0 × 730 × 0.01 = $14.60 | $29.20 |
Nearly all of the savings come from removing 19 hourly charges. LCU totals stay roughly the same. On a shared ALB they can come in slightly lower, because only the highest dimension of the combined traffic is billed. They can also rise if the many rules you add push rule evaluations above the other three dimensions. Replace H and L with the current pricing for your region before you rely on these figures.
What is an IngressGroup and how does it work in the AWS Load Balancer Controller?
An IngressGroup is the AWS Load Balancer Controller's way of mapping many Ingress objects to one ALB. By default the controller treats each Ingress as its own group and provisions a separate load balancer for it. Ingresses that set the same alb.ingress.kubernetes.io/group.name value are reconciled together as a single unit, which produces one ALB, one set of listeners, and a merged rule list. This works across namespaces, so the group is a cluster-wide resource while each Ingress stays namespaced.
Consider two Ingresses: shop/storefront, routing shop.example.com, and billing/api, routing billing.example.com/api. Both set group.name: shared-public. The controller does not create two ALBs. It merges their rules onto the shared listeners on ports 80 and 443, and it creates a target group for each backend Service each Ingress references.
How rule priority is decided
ALB evaluates listener rules in priority order, and the first match wins. That matters when two Ingresses claim overlapping hosts or paths. alb.ingress.kubernetes.io/group.order assigns each Ingress an integer, and lower values are evaluated first. Ingresses that share an order value are sorted by namespace and name, so their relative priority is deterministic. Set explicit orders when a catch-all path could shadow a more specific one. Otherwise priority depends on how the Ingresses happen to be named.
Shape of a shared ALB
- ALB
shared-public- Listener :443
- Rule (order 10)
shop.example.com/*→ TGshop-storefront-web - Rule (order 20)
billing.example.com/api/*→ TGbilling-api-svc - Rule (order 30)
admin.example.com/*→ TGops-admin-ui - Default action → fixed 404
- Rule (order 10)
- Listener :80 → redirect to :443
- Listener :443
The three Ingresses come from the shop, billing and ops namespaces, and each rule forwards to that Ingress's own target group.
# Two Ingresses in different namespaces joined into one ALB via group.name
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: storefront
namespace: shop
annotations:
alb.ingress.kubernetes.io/group.name: shared-public # same value => same ALB
alb.ingress.kubernetes.io/group.order: "10" # lower = evaluated first
alb.ingress.kubernetes.io/scheme: internet-facing
alb.ingress.kubernetes.io/listen-ports: '[{"HTTP": 80}, {"HTTPS": 443}]'
spec:
ingressClassName: alb
rules:
- host: shop.example.com
http:
paths:
- path: /
pathType: Prefix
backend:
service: {name: web, port: {number: 80}} # gets its own target group
---
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: api
namespace: billing
annotations:
alb.ingress.kubernetes.io/group.name: shared-public
alb.ingress.kubernetes.io/group.order: "20"
alb.ingress.kubernetes.io/scheme: internet-facing # keep ALB-level settings consistent across the group
spec:
ingressClassName: alb
rules:
- host: billing.example.com
http:
paths:
- path: /api
pathType: Prefix
backend:
service: {name: svc, port: {number: 8080}}
Two namespaced Ingresses share group.name shared-public, so the controller merges their rules onto one ALB's listeners and orders them by group.order.
Which ALB settings are shared across a group and which stay per-Ingress?
Because every member of an IngressGroup reconciles into one physical load balancer, any attribute that belongs to the ALB itself, and not to a rule, has to resolve to a single value. The controller merges annotations from all members. If two Ingresses disagree on an ALB-level value, such as one asking for internal and another for internet-facing, the controller does not pick a winner. Reconciliation for the whole group fails, and the error appears in the controller logs and in the Ingress events. Until someone fixes the conflict, changes to any member stop propagating, including changes from teams whose manifests are correct.
| Scope | Settings | Conflict behaviour |
|---|---|---|
| Load balancer (shared) | Scheme, subnets, security groups, idle timeout, access logs, WAF web ACL association | Must agree; a mismatch blocks reconciliation for the group |
| Listener (shared) | Listener ports, TLS security policy | Must agree for a given port |
| Per-Ingress | Host and path rules, target groups, backend health-check settings | Independent per member |
This produces lowest-common-denominator pressure. Suppose billing needs a strict TLS policy and a restrictive security group, while shop needs a long idle timeout for slow uploads. On a shared ALB, both teams get the union of those settings. Billing ends up with a longer timeout than it wants, and shop ends up with a security group that has to admit everyone's clients. Each relaxation widens the exposure of every service on the ALB.
If services differ in network exposure, compliance scope, or timeout requirements, give each set of requirements its own group. Consolidating only saves money when the members can genuinely share one security posture.
Who should consolidate ALBs, and when should you avoid it?
The best candidates are environments with many Ingresses and little traffic: dev, staging, per-branch preview environments, and internal tools such as dashboards and admin consoles. Each of these typically gets its own ALB by default, and each ALB pays the hourly charge whether it serves one request a day or none. When traffic is near zero, the hourly charge is almost the entire bill, so merging twenty such ALBs into one removes most of the cost.
When to keep ALBs separate
- High-traffic production services. LCU charges scale with traffic, not with the number of load balancers. Consolidating busy services saves only the hourly charges, which are small next to the LCU bill.
- Different trust boundaries. Services owned by different teams, or in different compliance scopes, should not share a listener, security groups, or a set of certificates.
- Very high rule counts. Rule evaluations are one LCU dimension. Each request that is evaluated against more rules than the free allowance adds to that dimension, so a heavily packed listener can raise LCU usage.
- Approaching per-ALB quotas. If rules, target groups, or certificates are close to their limits, you will soon have to split the ALB again.
Blast radius
The controller reconciles a group as a single unit. One malformed annotation, a reference to a missing Service, or an invalid group.order value in any member Ingress blocks updates for every Ingress in the group until someone fixes it. At runtime the risk is the same: if the shared ALB is misconfigured or deleted, every service behind it goes down together.
How do you find idle ALBs and implement a safe migration to a shared ALB?
Step 1: Inventory the controller's ALBs
Run kubectl get ingress -A -o wide and match each ADDRESS value to the DNSName returned by aws elbv2 describe-load-balancers. You can also confirm ownership with aws elbv2 describe-tags: the controller tags its ALBs with the cluster name and an ingress.k8s.aws/stack value that identifies the Ingress or group. Use the tags to separate controller-managed ALBs from ones created by hand or by Terraform, because you should not consolidate those through Kubernetes.
Step 2: Pick candidates from metrics
Pull RequestCount and ConsumedLCUs from the AWS/ApplicationELB namespace with aws cloudwatch get-metric-statistics. Cover at least one full business cycle, so batch jobs and month-end traffic show up. ALBs with low LCU usage across that window are paying mostly the hourly charge, which makes them the best candidates.
Step 3: Build the grouped Ingress in parallel
Create a new Ingress that has the group annotation and points at the same Service. Leave the old one in place. Check the result with aws elbv2 describe-rules and describe-target-health before any traffic moves. Pay attention to three differences:
- Health checks: These are set per target group, so the annotations need to carry over exactly.
- Security groups: The controller-managed group and the inbound CIDRs now apply to every member of the group.
- Target type: A different target type changes which source address pods and NetworkPolicies see.
Step 4: Shift DNS, then delete
Lower the record's TTL ahead of time. Then repoint the record, either by hand or by moving the ExternalDNS ownership annotation, so that two Ingresses never claim the same hostname. Watch HTTPCode_ELB_5XX_Count and HTTPCode_Target_5XX_Count on the shared ALB. Delete the old Ingress only after the old TTL has expired and the old ALB's RequestCount has dropped to zero.
#!/usr/bin/env bash
# Steps 1-2: list the ALBs this cluster's controller owns, with 30-day traffic totals.
# Assumes GNU date and AWS CLI v2 credentials for the cluster's account and region.
set -euo pipefail
CLUSTER="prod-eks-01" # placeholder: must match the controller's --cluster-name
START=$(date -u -d '30 days ago' +%Y-%m-%dT%H:%M:%SZ)
END=$(date -u +%Y-%m-%dT%H:%M:%SZ)
# Ingress ADDRESS values, to cross-check against the DNSName column below
kubectl get ingress -A -o wide
printf '%-45s %-60s %12s %12s\n' STACK DNSNAME REQUESTS LCU_SUM
for ARN in $(aws elbv2 describe-load-balancers \
--query "LoadBalancers[?Type=='application'].LoadBalancerArn" --output text); do
TAGS=$(aws elbv2 describe-tags --resource-arns "$ARN" --query 'TagDescriptions[0].Tags' --output json)
# Skip ALBs not owned by this cluster's controller (hand-made or Terraform-managed)
OWNER=$(echo "$TAGS" | jq -r '.[] | select(.Key=="elbv2.k8s.aws/cluster") | .Value')
[ "$OWNER" = "$CLUSTER" ] || continue
STACK=$(echo "$TAGS" | jq -r '.[] | select(.Key=="ingress.k8s.aws/stack") | .Value')
DNS=$(aws elbv2 describe-load-balancers --load-balancer-arns "$ARN" \
--query 'LoadBalancers[0].DNSName' --output text)
DIM="${ARN#*:loadbalancer/}" # CloudWatch dimension is app/<name>/<id>
# Daily sums over the window; low totals mean the ALB mostly pays the hourly charge
for METRIC in RequestCount ConsumedLCUs; do
VAL=$(aws cloudwatch get-metric-statistics --namespace AWS/ApplicationELB \
--metric-name "$METRIC" --dimensions Name=LoadBalancer,Value="$DIM" \
--start-time "$START" --end-time "$END" --period 86400 --statistics Sum \
--query 'sum(Datapoints[].Sum)' --output text)
eval "${METRIC}=\$VAL"
done
printf '%-45s %-60s %12s %12s\n' "$STACK" "$DNS" "$RequestCount" "$ConsumedLCUs"
done
A shell script that uses kubectl, jq, the elbv2 tag API and CloudWatch to list the ALBs owned by one cluster's load balancer controller, along with their 30-day request and LCU totals, so you can rank consolidation candidates.
How do you govern who can join a shared ALB with IngressClassParams and RBAC?
Pin the group centrally, not in team manifests. Create an IngressClassParams object that sets the group name and the ALB-level settings, such as scheme, subnets, SSL policy, tags and load balancer attributes. Reference it from an IngressClass. Every Ingress that uses that class joins the group and inherits those values, and values set in IngressClassParams take precedence over conflicting Ingress annotations. Teams then pick a class name and stop copying a block of alb.ingress.kubernetes.io/* annotations. That removes the drift that causes the most tedious debugging, for example two Ingresses in one group disagreeing on an ALB-wide setting and the controller refusing to reconcile.
RBAC cannot restrict which ingressClassName a user puts in an Ingress spec. Use the namespaceSelector in IngressClassParams to limit the production class to namespaces carrying an approved label. That makes the label the real gate. Only platform admins should be able to modify namespaces, IngressClass and IngressClassParams, all of which are cluster-scoped. If a team can relabel its own namespace, it can join the production ALB.
Membership is not the only risk. Rules from every Ingress in a group merge into one listener, so a team can claim another team's hostname or add a broader path that captures traffic, and group.order lets it raise its priority. Enforce host ownership per namespace with a validating admission policy.
Choose group boundaries the way you would choose network boundaries. Everyone in a group shares a listener, a security group and a blast radius. Group by environment or trust boundary first, and by team only when teams need isolation from each other.
# Cluster-scoped and owned by platform admins. Teams only set ingressClassName.
apiVersion: elbv2.k8s.aws/v1beta1
kind: IngressClassParams
metadata:
name: prod-public
spec:
# The real gate: only namespaces carrying this label may use the class.
# Restrict who can patch namespace labels, or this check is meaningless.
namespaceSelector:
matchLabels:
alb.example.com/prod-public: "approved"
# Pins group membership. Teams cannot pick a different group via annotations.
group:
name: prod-public
# ALB-wide settings, defined once. These override conflicting Ingress annotations.
scheme: internet-facing
sslPolicy: ELBSecurityPolicy-TLS13-1-2-2021-06
tags:
- key: environment
value: production
- key: owner
value: platform-team
loadBalancerAttributes:
- key: deletion_protection.enabled
value: "true"
- key: idle_timeout.timeout_seconds
value: "60"
---
apiVersion: networking.k8s.io/v1
kind: IngressClass
metadata:
name: alb-prod-public
spec:
controller: ingress.k8s.aws/alb
parameters:
apiGroup: elbv2.k8s.aws
kind: IngressClassParams
name: prod-public
An IngressClassParams object pins the group name and ALB-wide settings and limits use to namespaces with an approved label, and an IngressClass exposes it so teams join the shared ALB by setting only ingressClassName.
How do you plan quotas, TLS and cost attribution for a shared ALB, and what are the alternatives?
Per-load-balancer quotas matter more once dozens of Ingresses share one ALB. The relevant limits are rules per ALB, target groups per ALB, and certificates per listener. Look these up in Service Quotas for your account and region rather than relying on remembered numbers, because defaults change and some can be raised. Every path and host rule from every member Ingress counts against the same listener, so a busy group can reach the rule limit before it causes any traffic problem.
TLS consolidates cleanly. The HTTPS listener holds multiple certificates and uses SNI to present the one that matches the client's requested hostname, so many hostnames can share one listener without wildcard certificates.
Consolidation moves cost onto one ALB, so chargeback has to come from finer-grained data:
- CloudWatch: Use metrics with the
TargetGroupdimension, such asRequestCount, to measure each Ingress's share of the traffic. - Access logs: These record the target group ARN on each request, which lets you join bytes and requests to owners.
- Tagging: Tag target groups by team or cost center, because the shared ALB can carry only one set of tags.
A simple allocation formula: team cost = ALB cost × (team requests ÷ total requests). Swap requests for bytes if your traffic is bandwidth-heavy.
| Option | Cost | Blast radius | Operational effort |
|---|---|---|---|
| One ALB per Ingress | Highest; idle hourly charges add up | Smallest | Low per app, high in aggregate |
| Shared ALB per environment/team | Low | Group-wide | Moderate; needs governance |
| One ALB per cluster | Lowest of the ALB options | Whole cluster | Quota pressure; you need a quota-limit strategy |
| In-cluster proxy behind one LB | Low LB cost, plus proxy compute | Proxy is a single point of failure | Highest; you run the data plane |
How OneEnv can help
Disclosure: OneEnv is the product behind this blog.
OneEnv (oneenv.io) is a workspace-based governance platform for the things services share — environment variables, database structure, API routes and validation rules. A change to a shared value is staged on a branch, reviewed once, and then every affected service explicitly approves or rejects it before it goes live, so you can see who a change touches before it ships instead of finding out in production.
Applied to alb ingress group cost, this is where it helps:
Saves time
- Every service that inherits a shared value is listed in one place, so nobody searches repos and chats to find out who is affected.
- One review per branch replaces coordinating each team separately; each service still keeps its own approve/reject.
- Reviewers see the exact diff and the list of affected services up front, so approval is a decision rather than an investigation.
Saves cost
- Fewer production incidents and rollbacks caused by a shared value, route or column changing under a consumer unannounced.
- Less duplicated configuration to maintain: one shared definition inherited by many services.
- Per-service approve/reject means a bad shared value can be refused where it would break something, before it is live.
- OneEnv has a free plan (1 workspace, unlimited services and members, full governance), so trying it costs nothing.
These are qualitative benefits, not measured results — how much you save depends on how many services share the value.
Want to try it? Start at oneenv.io.