How to size Pod and Service CIDRs
- Pick your platform to load its defaults, or type your own cluster (Pod) CIDR, node CIDR mask size, Service CIDR and kubelet maxPods. Add the node subnet or VPC to check it too.
- Read the tiles: how many nodes the cluster CIDR holds, how many Pod addresses each node block has, and whether kubelet's maxPods or the block is the limit that binds.
- Check the overlaps. The Pod CIDR, Service CIDR, node network and Docker's
172.17.0.0/16must not share addresses; Apply fixes moves the range at fault to the nearest free private block. - Copy the kubeadm configuration or the k3s flags, or copy the link to share the exact plan.
This planner is for clusters whose Pods get addresses from a cluster CIDR: kubeadm and other kube-controller-manager setups, k3s, GKE VPC-native, AKS kubenet and Azure CNI Overlay, Cilium cluster-pool — IPv4, IPv6 or dual-stack. On Amazon EKS with the VPC CNI, Pods take addresses from VPC subnets instead — size those with the EKS max Pods calculator and the VPC subnet planner.
How node CIDR blocks are carved
kube-controller-manager cuts the cluster CIDR into equal blocks of --node-cidr-mask-size and gives each node the next free one: 2^(mask − prefix) blocks in all. Inside a block, host-local IPAM keeps the network address, the bridge gateway and the broadcast address, so a block of 2^(32 − mask) addresses holds that many minus 3 Pods. With the default maxPods of 110:
| Node mask | Addresses | Pod IPs | Pods per node | Binds | Nodes in a /16 | Pods in a /16 | Nodes in a /14 | Pods in a /14 | GKE max Pods |
|---|---|---|---|---|---|---|---|---|---|
/20 | 4,096 | 4,093 | 110 | maxPods | 16 | 1,760 | 64 | 7,040 | 2,048 |
/21 | 2,048 | 2,045 | 110 | maxPods | 32 | 3,520 | 128 | 14,080 | 1,024 |
/22 | 1,024 | 1,021 | 110 | maxPods | 64 | 7,040 | 256 | 28,160 | 512 |
/23 | 512 | 509 | 110 | maxPods | 128 | 14,080 | 512 | 56,320 | 256 |
/24 | 256 | 253 | 110 | maxPods | 256 | 28,160 | 1,024 | 112,640 | 128 |
/25 | 128 | 125 | 110 | maxPods | 512 | 56,320 | 2,048 | 225,280 | 64 |
/26 | 64 | 61 | 61 | addresses | 1,024 | 62,464 | 4,096 | 249,856 | 32 |
/27 | 32 | 29 | 29 | addresses | 2,048 | 59,392 | 8,192 | 237,568 | 16 |
/28 | 16 | 13 | 13 | addresses | 4,096 | 53,248 | 16,384 | 212,992 | 8 |
GKE sizes the other way round: each node's range has at least twice as many addresses as its maximum Pods, rounded up to a power of two (/24 for 110 Pods, /26 for 32), so addresses freed by a deleted Pod are not reused immediately. The last column is the most Pods GKE allows for that block size.
kubeadm also refuses a node mask more than 16 bits longer than the Pod CIDR prefix (a /8 with /25 blocks). kube-controller-manager only enforces that limit for IPv6; for IPv4 it accepts any mask from the cluster prefix to /32.
Platform defaults
| Platform | Pod CIDR | Node mask | Service CIDR | maxPods | Nodes | Pods per node | kube-dns |
|---|---|---|---|---|---|---|---|
| kubeadm + Flannel | 10.244.0.0/16 | /24 | 10.96.0.0/12 | 110 | 256 | 110 | 10.96.0.10 |
| k3s | 10.42.0.0/16 | /24 | 10.43.0.0/16 | 110 | 256 | 110 | 10.43.0.10 |
| Dual-stack | 10.42.0.0/16,2001:db8:42::/56 | /24 | 10.43.0.0/16,2001:db8:43::/112 | 110 | 256 | 110 | 10.43.0.10 |
| GKE VPC-native | 10.4.0.0/14 | /24 | 34.118.224.0/20 | 110 | 1,024 | 110 | 34.118.224.10 |
| AKS CNI Overlay | 10.244.0.0/16 | /24 | 10.0.0.0/16 | 250 | 256 | 250 | 10.0.0.10 |
| Cilium cluster-pool | 10.0.0.0/8 | /24 | 10.96.0.0/12 | 110 | 61,440 | 110 | 10.96.0.10 |
- kubeadm sets no Pod CIDR by default; Flannel expects
10.244.0.0/16, passed tokubeadm initas--pod-network-cidr. The Service subnet defaults to10.96.0.0/12. - GKE chooses a
/14Pod range when you don't set one (the address shown is an example) and, from Standard 1.29 and Autopilot 1.27, puts Services on the Google-managed34.118.224.0/20. GKE's kube-dns address is not shown here because GKE assigns it. - AKS Azure CNI Overlay gives every node a fixed
/24and allows up to 250 Pods per node; its Service CIDR must be smaller than/12. - Cilium's cluster-pool default
10.0.0.0/8overlaps kubeadm's Service range and every node network in 10.x — 2 overlaps for the row above. SetclusterPoolIPv4PodCIDRListbefore installing; existing entries can't be changed later.
Service CIDR rules
- Largest: a
/12for IPv4. kubeadm enforces it on every version, and kube-apiserver did until 1.34 with "specified --service-cluster-ip-range is too large; for 32-bit addresses, the mask must be >= 12". - Smallest: kubeadm wants at least 10 addresses, because kube-dns takes the 10th — a
/28is the smallest range that works. - Reserved: the network and broadcast addresses are never handed out, so a
/nholds2^(32 − n) − 2ClusterIPs. ThekubernetesService always takes the first usable address. - Static band: the lowest
min(max(16, size / 16), 256)addresses are kept for Services that ask for a specific ClusterIP, such as kube-dns; dynamic allocation uses them only when the rest is exhausted. - Growing it: from Kubernetes 1.33 you can add a ServiceCIDR object instead of rebuilding the cluster.
| Service CIDR | ClusterIPs | kubernetes.default | kube-dns (10th) | Static band | Dynamic |
|---|---|---|---|---|---|
10.96.0.0/12 | 1,048,574 | 10.96.0.1 | 10.96.0.10 | 256 | 1,048,318 |
10.96.0.0/16 | 65,534 | 10.96.0.1 | 10.96.0.10 | 256 | 65,278 |
10.96.0.0/20 | 4,094 | 10.96.0.1 | 10.96.0.10 | 256 | 3,838 |
10.96.0.0/24 | 254 | 10.96.0.1 | 10.96.0.10 | 16 | 238 |
10.96.0.0/28 | 14 | 10.96.0.1 | 10.96.0.10 | 0 | 14 |
IPv6 and dual-stack clusters
Range fields take one CIDR or an IPv4 and an IPv6 CIDR separated by a comma, as the flags do — --cluster-cidr with 10.42.0.0/16,2001:db8:42::/56. kube-controller-manager accepts at most two, one per family, and gives each node a block of each (spec.podCIDRs). The IPv6 node mask is --node-cidr-mask-size-ipv6, default /64; on a dual-stack cluster the plain --node-cidr-mask-size is refused in favour of the -ipv4 and -ipv6 flags.
For IPv6, and only for IPv6, the node mask may be at most 16 bits longer than the cluster prefix — so with /64 blocks the cluster CIDR must be a /48 or longer:
| IPv6 cluster CIDR | /64 node blocks | Pods at maxPods 110 |
|---|---|---|
/44 | refused | kube-controller-manager won't start |
/48 | 65,536 | 7,208,960 |
/52 | 4,096 | 450,560 |
/56 | 256 | 28,160 |
/60 | 16 | 1,760 |
/64 | 1 | 110 |
Inside an IPv6 block, CNI host-local IPAM keeps only the network address and the gateway — IPv6 has no broadcast address — so a /64 has 264 − 2 Pod addresses.
IPv6 Service CIDR rules
- Largest: kubeadm caps it at 20 host bits —
/108("for 128-bit addresses, the mask must be >= 108"), as kube-apiserver did before 1.34. From 1.34 the IPAddress allocator accepts down to/64and refuses anything larger. - Before 1.34 the bitmap allocator used at most 65,536 addresses of an IPv6 range, so kubeadm notes that
/108to/112is clamped to/112; k3s documents/112as its largest IPv6 Service CIDR. - Reserved: only the network address, so a
/nholds 2128 − n − 1 ClusterIPs. The static band is the samemin(max(16, size / 16), 256).
| IPv6 Service CIDR | ClusterIPs (1.34+) | Before 1.34 | 10th address (kube-dns) | Static band |
|---|---|---|---|---|
fd00:10:96::/108 | 1,048,575 | 65,535 | fd00:10:96::a | 256 |
fd00:10:96::/112 | 65,535 | 65,535 | fd00:10:96::a | 256 |
fd00:10:96::/116 | 4,095 | 4,095 | fd00:10:96::a | 256 |
fd00:10:96::/120 | 255 | 255 | fd00:10:96::a | 16 |
fd00:10:96::/124 | 15 | 15 | fd00:10:96::a | 0 |
Unique local ranges (fd00::/8, RFC 4193) are the usual choice for Pods and Services; a global prefix makes Pods directly routable, which is a feature only with a firewall in front. Amazon EKS IPv6 clusters are single-stack: Pods take addresses from the subnet's /64 and EKS assigns the Service CIDR from fc00::/7 itself.
Overlaps that break clusters
A Pod or Service range that shares addresses with something you route to wins locally: nodes send that traffic into the overlay or to kube-proxy instead of the real host. The usual collisions, each computed by the planner with its suggested fix:
| Case | Pod · Service · Node | First overlap | Fix |
|---|---|---|---|
| Pod CIDR on Docker's bridge | 172.17.0.0/16 · 10.96.0.0/12 · 10.0.0.0/16 | Pod CIDR / docker0: 172.17.0.0/16 (65,536 addresses) | Pod CIDR → 172.18.0.0/16 |
| Cilium's default pool on a 10.x VPC | 10.0.0.0/8 · 10.96.0.0/12 · 10.10.0.0/16 | Pod CIDR / Node network: 10.10.0.0/16 (65,536 addresses) | Pod CIDR → 10.128.0.0/9 |
| Service CIDR equal to a peered VPC | 10.244.0.0/16 · 10.100.0.0/16 · 10.100.0.0/16 | Service CIDR / Node network: 10.100.0.0/16 (65,536 addresses) | Service CIDR → 10.101.0.0/16 |
| Calico's 192.168.0.0/16 on an office network | 192.168.0.0/16 · 10.96.0.0/12 · 192.168.1.0/24 | Pod CIDR / Node network: 192.168.1.0/24 (256 addresses) | Pod CIDR → 10.0.0.0/16 |
- docker0: Docker's default bridge takes
172.17.0.0/16on every host that runs it — CI runners, bastions, build hosts. Keep Pod and Service ranges out of it, or move the bridge withbipindaemon.json. - VPC peering, VPN and on-prem: overlay Pod ranges are not routed in the VPC, but any peered network, VPN or on-prem range inside them becomes unreachable from Pods. Check the whole estate with the CIDR overlap checker.
- Office and home networks: Calico's sample pool
192.168.0.0/16covers most LANs; give it a 10.x or 100.64.x range instead.
Verification
- Node blocks, the node mask rules and the Service-range skipping come from kube-controller-manager's source (the
cidrsetpackage andrange_allocator.go); the unit tests port its vectors — 256 blocks for a/16at/24,127.0.0.0/8at/32, block indexes and occupied ranges — and read 2026-11-20. - Error texts are quoted from kubeadm's validation package and its constants and kube-apiserver's Service range check; the static band and first-address rules from the Kubernetes Service ClusterIP allocation docs and
calculateRangeOffset, which gives a range of 16 addresses or fewer no static band. - IPv6 and dual-stack: the 16-bit node-mask limit and the
/64default from kube-controller-manager's source, the dual-stack flag checks from itsvalidateCIDRs, the/64floor and 2n − 1 ClusterIPs from the 1.34+ IPAddress allocator, the 65,536 cap from the old bitmap allocator, and the dual-stack example from the k3s documentation (read 2026-11-20). - Platform defaults come from the kubeadm, k3s, GKE, AKS and Cilium documentation linked below. The engine runs at 100% line and branch coverage, and the e2e spec proves your ranges never leave this tab.
- cidrset (kube-controller-manager)
- kubeadm validation
- Service ClusterIP allocation
- IPv4/IPv6 dual-stack
- IPAddress allocator (1.34+)
- k3s dual-stack options
- kubeadm configuration (v1beta4)
- kubelet configuration
- CNI host-local IPAM
- k3s server flags
- GKE: maximum Pods per node
- GKE: VPC-native clusters
- AKS: Azure CNI Overlay
- Cilium cluster-pool IPAM