CIDR reference · IPv4

The /22 CIDR block

1,024 addresses, 1,022 usable, subnet mask 255.255.252.0.

/22 · 255.255.252.0 Open in the calculator

1,024 addresses (1,022 usable). Common for office networks that outgrew a /24 and for Kubernetes node subnets. The mask 255.255.252.0 is often misread; the 252 lives in the third octet, so the block spans four consecutive third-octet values, for example 10.0.0.0 to 10.0.3.255.

Key numbers

Prefix length/22 (22 network bits, 10 host bits)
Subnet mask255.255.252.0
Mask in binary11111111.11111111.11111100.00000000
Wildcard mask0.0.3.255
Total addresses1,024
Usable hosts1,022 (total minus network and broadcast)
Contains4 × /24 networks
Block sizeIncrements of 4 in octet 3

Example ranges

Private (RFC 1918) blocks of this size. Click one to open it in the calculator.

BlockFirst addressLast addressUsable hosts
10.0.0.0/2210.0.0.010.0.3.25510.0.0.1 – 10.0.3.254
172.16.0.0/22172.16.0.0172.16.3.255172.16.0.1 – 172.16.3.254
192.168.0.0/22192.168.0.0192.168.3.255192.168.0.1 – 192.168.3.254

Usable addresses in the cloud

Cloud providers reserve a few addresses in every subnet for the router, DNS and future use, so the usable count is lower than the formula gives.

ProviderUsable in a /22Notes
AWS VPC subnet1,019Allowed (/16 to /28). AWS reserves the first four addresses and the last one.
Azure virtual network subnet1,019Allowed. Azure reserves the first four addresses and the last one.
Google Cloud subnet1,020Allowed. Google Cloud reserves the first two and the last two addresses.

How the numbers are derived

An IPv4 address has 32 bits. A /22 uses 22 of them for the network, leaving 10 host bits, so the block has 210 = 1,024 addresses. The first address (all host bits 0) is the network address and the last (all host bits 1) is the broadcast address, which leaves 1,022 for hosts. The subnet mask is 22 ones followed by 10 zeros, written in dotted decimal as 255.255.252.0; the wildcard mask 0.0.3.255 is its inverse, used in Cisco ACLs and OSPF configuration.

FAQ

How many hosts can a /22 have?

1,024 addresses in total, of which 1,022 are usable after removing the network and broadcast addresses. Cloud providers reserve a few more: 1,019 usable in AWS and Azure, 1,020 in Google Cloud.

How many /24 subnets fit in a /22?

4. Each step of the prefix length halves or doubles the block, so a /22 contains 2^(24 − 22) = 4 networks of /24 size.