Last reviewed: May 2026
This subnet cheat sheet covers every IPv4 CIDR prefix from /0 to /32, providing the subnet mask, wildcard mask, total IP count, usable host count, and typical use case for each prefix length. Bookmark this page as your go-to reference whether you're a network engineer designing a corporate LAN, a CCNA student preparing for the exam, or a cloud architect planning AWS VPC, Azure VNet, or GCP subnet ranges.
Calculate any subnet instantly →Rows highlighted in blue are the most commonly referenced prefixes in real-world networking and cloud deployments.
| Prefix | Subnet Mask | Wildcard Mask | Total IPs | Usable Hosts | Typical Use |
|---|---|---|---|---|---|
| /0 | 0.0.0.0 | 255.255.255.255 | 4,294,967,296 | 4,294,967,294 | Default route (all IPv4 addresses) |
| /1 | 128.0.0.0 | 127.255.255.255 | 2,147,483,648 | 2,147,483,646 | Half of IPv4 space |
| /2 | 192.0.0.0 | 63.255.255.255 | 1,073,741,824 | 1,073,741,822 | Quarter of IPv4 space |
| /3 | 224.0.0.0 | 31.255.255.255 | 536,870,912 | 536,870,910 | Large regional allocation |
| /4 | 240.0.0.0 | 15.255.255.255 | 268,435,456 | 268,435,454 | Large regional allocation |
| /5 | 248.0.0.0 | 7.255.255.255 | 134,217,728 | 134,217,726 | Large regional allocation |
| /6 | 252.0.0.0 | 3.255.255.255 | 67,108,864 | 67,108,862 | Large regional allocation |
| /7 | 254.0.0.0 | 1.255.255.255 | 33,554,432 | 33,554,430 | Large regional allocation |
| /8 | 255.0.0.0 | 0.255.255.255 | 16,777,216 | 16,777,214 | Class A / ISP allocation (e.g. 10.0.0.0/8 RFC 1918) |
| /9 | 255.128.0.0 | 0.127.255.255 | 8,388,608 | 8,388,606 | Large enterprise or ISP block |
| /10 | 255.192.0.0 | 0.63.255.255 | 4,194,304 | 4,194,302 | Large enterprise block |
| /11 | 255.224.0.0 | 0.31.255.255 | 2,097,152 | 2,097,150 | Large enterprise block |
| /12 | 255.240.0.0 | 0.15.255.255 | 1,048,576 | 1,048,574 | 172.16.0.0/12 RFC 1918 private range |
| /13 | 255.248.0.0 | 0.7.255.255 | 524,288 | 524,286 | Large enterprise aggregation |
| /14 | 255.252.0.0 | 0.3.255.255 | 262,144 | 262,142 | Large enterprise aggregation |
| /15 | 255.254.0.0 | 0.1.255.255 | 131,072 | 131,070 | Large enterprise aggregation |
| /16 | 255.255.0.0 | 0.0.255.255 | 65,536 | 65,534 | AWS VPC root CIDR / campus network |
| /17 | 255.255.128.0 | 0.0.127.255 | 32,768 | 32,766 | Half of a /16 |
| /18 | 255.255.192.0 | 0.0.63.255 | 16,384 | 16,382 | Quarter of a /16 |
| /19 | 255.255.224.0 | 0.0.31.255 | 8,192 | 8,190 | Large building or campus segment |
| /20 | 255.255.240.0 | 0.0.15.255 | 4,096 | 4,094 | Large AZ subnet / EKS node group |
| /21 | 255.255.248.0 | 0.0.7.255 | 2,048 | 2,046 | Large VLAN segment |
| /22 | 255.255.252.0 | 0.0.3.255 | 1,024 | 1,022 | Large office VLAN / EKS node group |
| /23 | 255.255.254.0 | 0.0.1.255 | 512 | 510 | Medium office VLAN |
| /24 | 255.255.255.0 | 0.0.0.255 | 256 | 254 | Standard subnet (most common) |
| /25 | 255.255.255.128 | 0.0.0.127 | 128 | 126 | Half of /24 |
| /26 | 255.255.255.192 | 0.0.0.63 | 64 | 62 | Small department / AWS workload / Azure Firewall min |
| /27 | 255.255.255.224 | 0.0.0.31 | 32 | 30 | Azure GatewaySubnet minimum |
| /28 | 255.255.255.240 | 0.0.0.15 | 16 | 14 | AWS minimum subnet (11 usable after reservation) |
| /29 | 255.255.255.248 | 0.0.0.7 | 8 | 6 | Very small segment / management VLAN |
| /30 | 255.255.255.252 | 0.0.0.3 | 4 | 2 | Point-to-point links |
| /31 | 255.255.255.254 | 0.0.0.1 | 2 | 2* | RFC 3021 point-to-point (no broadcast) |
| /32 | 255.255.255.255 | 0.0.0.0 | 1 | 1* | Host route / loopback interface |
The "Usable Hosts" column above reflects standard RFC 950 calculations (total IPs minus 2 for network and broadcast). Cloud providers reserve additional IPs:
| Provider | Reserved IPs Per Subnet | Example: /24 usable | Example: /28 usable |
|---|---|---|---|
| Standard (RFC 950) | 2 | 254 | 14 |
| AWS | 5 (.0, .1, .2, .3, .255) | 251 | 11 |
| Azure | 5 (.0, .1, .2, .3, .255) | 251 | 11 |
| GCP | 4 (.0, gateway, second-to-last, .255) | 252 | 12 |
Use the AWS VPC Calculator for accurate cloud-adjusted subnet planning.
| Use Case | Recommended Prefix | Usable Hosts | Notes |
|---|---|---|---|
| Home / SOHO network | /24 | 254 | Default for most home routers |
| AWS VPC root CIDR | /16 | 65,534 | Provides room to subdivide into many subnets |
| Standard AWS workload subnet | /24 | 251 (AWS) | Balance of size and address efficiency |
| Small AWS workload subnet | /26 | 59 (AWS) | Dev environments, small services |
| Azure GatewaySubnet | /27 minimum | 27 (Azure) | /27 required; /26 or larger recommended |
| Azure Firewall / Bastion | /26 minimum | 59 (Azure) | AzureFirewallSubnet, AzureBastionSubnet |
| Point-to-point WAN link | /30 | 2 | One IP each end of the link |
| Point-to-point (efficient) | /31 | 2 | RFC 3021; no wasted addresses |
| Management VLAN | /29 | 6 | Switches, routers, OOB access |
| Loopback / host route | /32 | 1 | BGP router ID, security group rules |
| Default route (all traffic) | /0 | — | 0.0.0.0/0 matches all destinations |