What is Subnetting?
Subnetting is the process of dividing a single network into smaller network segments. It helps optimize network performance, improve security, and manage IP address allocation. By breaking down a large network into smaller, more manageable pieces, network administrators can create more efficient routing, isolate network traffic, and implement better security controls.
CIDR Notation
CIDR (Classless Inter-Domain Routing) notation uses a suffix like /24 to indicate the number of bits in the network portion of an IP address. For example, 192.168.1.0/24 indicates that the first 24 bits (three octets) define the network, leaving 8 bits for host addresses.
This approach replaced the older classful networking model and allows for more flexible allocation of IP address blocks. For a complete reference of CIDR notation, subnet masks, and usable IPs, see our CIDR Reference page.
Reserved IPs by Cloud Providers
When planning your cloud infrastructure, it's important to understand that cloud providers reserve certain IP addresses within each subnet for their own use. This affects the number of usable IP addresses available for your resources.
AWS
AWS reserves the first 4 IP addresses and the last IP address in each subnet:
- The first address is the network address
- The second address (.1) is used for the VPC router
- The third address (.2) is for AWS DNS
- The fourth address (.3) is reserved for future use
- The last address is the broadcast address
Azure
Azure reserves the first 5 IP addresses and the last IP address in each subnet:
- The first address is the network address
- The second address (.1) is reserved for the default gateway
- The third and fourth addresses (.2, .3) are reserved for Azure DNS
- The fifth address (.4) is reserved for future use
- The last address is the broadcast address
Google Cloud
Google Cloud Platform reserves 4 IP addresses in each subnet:
- The first address is the network address
- The second address (.1) is reserved as the default gateway
- The second-to-last address is for future use
- The last address is the broadcast address
Understanding these reserved addresses is crucial when planning your network architecture, especially when working with smaller subnet sizes where every available IP address counts. Our subnet calculator automatically accounts for these reserved addresses when you select the appropriate cloud provider mode.