🌐 IP Subnet Calculator
Calculate subnet masks, network addresses, broadcast addresses, and usable host ranges for any CIDR block.
192.168.1.0255.255.255.0192.168.1.255192.168.1.1192.168.1.254254192.168.1.0/24What is VLSM and why is it more efficient than fixed-length subnetting?
Fixed-length subnetting divides a network into equal-sized subnets. VLSM (Variable Length Subnet Masking) allows different subnet sizes within the same network. Example: you have 192.168.1.0/24 and need subnets for 100 hosts, 50 hosts, and 10 hosts. Fixed /26 (62 usable hosts each): three subnets of 62 hosts each wastes IPs in the smaller subnets. VLSM: /25 (126 hosts) for the 100-host subnet, /26 (62 hosts) for the 50-host subnet, /28 (14 hosts) for the 10-host subnet. VLSM uses the address space far more efficiently. All modern routing protocols (OSPF, EIGRP, BGP) support VLSM.
How many usable host addresses does a /30 network have and why is it used for point-to-point links?
A /30 has 4 total addresses: network address, 2 usable hosts, broadcast. The 2 usable addresses are exactly what a point-to-point link needs — one IP for each end of the link. Using a /30 instead of a /29 (6 usable hosts) or /28 (14 usable hosts) conserves IP space. In router-to-router links (between two routers, or router to firewall), a /30 is the standard. For very large networks or where IP space is extremely limited, /31 (2 addresses, no broadcast per RFC 3021) is used — each end takes one address with no wasted network/broadcast addresses.
What is the difference between the network address and the broadcast address?
In any subnet, the first address (all host bits = 0) is the network address — it identifies the network itself and cannot be assigned to a host. The last address (all host bits = 1) is the broadcast address — packets sent to it are delivered to all hosts in the subnet. Both are reserved and cannot be used as host addresses. For a /24: 192.168.1.0 is the network address, 192.168.1.255 is broadcast, 192.168.1.1 through 192.168.1.254 are usable (254 hosts). AWS reserves 5 addresses per subnet (first 4 and last 1), further reducing usable count.
What IP address ranges are reserved and cannot be used on the public internet?
RFC 1918 private ranges: 10.0.0.0/8, 172.16.0.0/12, 192.168.0.0/16. Loopback: 127.0.0.0/8 (localhost). Link-local: 169.254.0.0/16 (APIPA — assigned when DHCP fails). Documentation/examples: 192.0.2.0/24, 198.51.100.0/24, 203.0.113.0/24 (TEST-NET). Multicast: 224.0.0.0/4. Broadcast: 255.255.255.255/32. Shared address space (CGNAT): 100.64.0.0/10. Future use: 240.0.0.0/4. All other ranges are potentially publicly routable. When designing internal networks, only use RFC 1918 ranges to avoid conflicts with public internet routing.
How does subnetting relate to CIDR notation?
CIDR (Classless Inter-Domain Routing) is just a compact notation for expressing subnets. 192.168.1.0/24 means: IP address 192.168.1.0 with the first 24 bits being the network portion. Before CIDR (1981-1993), addresses were Class A (/8), Class B (/16), or Class C (/24) with no flexibility. CIDR allowed arbitrary prefix lengths, dramatically extending IPv4's lifespan. Route summarization (supernetting) works the same way: multiple /24 networks can be summarized as a /22 when advertising to external routers, reducing routing table size.
How many subnets can I create from a /24 network?
Borrowing bits from the host portion creates subnets. From a /24: borrow 1 bit → 2 subnets (/25, 128 hosts each). Borrow 2 bits → 4 subnets (/26, 64 each). Borrow 3 bits → 8 subnets (/27, 32 each). Borrow 4 bits → 16 subnets (/28, 16 each). Borrow 5 bits → 32 subnets (/29, 8 each). Borrow 6 bits → 64 subnets (/30, 4 each). The general formula: number of subnets = 2^borrowed bits. Usable hosts per subnet = 2^remaining host bits - 2 (subtracting network and broadcast addresses).
What other network tools are on this site?
The CIDR Calculator is a companion tool focused on CIDR notation and address range display rather than VLSM planning. The Bandwidth Calculator estimates data transfer capacity for planned network links. The chmod Calculator handles Unix file permission calculations — another bit-math concept common in network administration. The curl Builder generates requests that exercise network endpoints. The HTTP Status Codes reference covers error codes from network services. All are in the Dev Tools section.
📊 Key Data Points
First and last reserved
Network address and broadcast address are reserved — a /24 has 254 usable hosts, not 256
AWS adds 3 more
AWS reserves 4 addresses at the start and 1 at the end of each subnet — a /24 has 251 usable IPs in AWS
Subnet mask = bit count
255.255.255.0 = /24 because there are 24 consecutive 1-bits in the subnet mask
IP Subnet Calculator -- Complete USA Guide 2026
Subnet calculations appear constantly in network configuration: AWS VPC planning, Kubernetes pod CIDR allocation, firewall rule writing, and server network configuration. Getting the network address, broadcast address, and usable host range wrong causes networking issues that are hard to diagnose.
This calculator shows all subnet properties from a CIDR block or IP + subnet mask. Runs in your browser.
**Long-tail searches answered here:** ip subnet calculator online free, ipv4 subnetting tool browser, subnet mask calculator online free.
For CIDR notation, see the CIDR Calculator.
🔬 How This Calculator Works
Calculates subnet properties from a CIDR block or IP address + subnet mask: network address, broadcast address, first/last usable host, subnet mask in dotted-decimal and CIDR notation, and total/usable host count. Also splits a larger network into equal subnets and calculates whether two IPs are on the same subnet.
✅ What You Can Calculate
Subnet properties from CIDR
Enter 192.168.10.0/24 and get: network address, broadcast address, first/last usable host, subnet mask, and 254 usable hosts — all at once.
Subnet mask conversion
Converts between prefix length (/24) and dotted-decimal subnet masks (255.255.255.0) — both forms are needed depending on your router, firewall, or cloud console.
Same-subnet check
Check if two IP addresses are on the same subnet. IP1 & mask == IP2 & mask — the calculator handles the bitwise arithmetic.
Network subdivision
Split a larger network (e.g. a /16) into smaller equal subnets of a specified size — useful for VPC subnet planning.
🎯 Real Scenarios & Use Cases
AWS VPC subnet planning
Calculate subnet properties before creating VPC subnets in AWS. You cannot resize a subnet after creation.
Kubernetes network planning
Kubernetes needs non-overlapping CIDR blocks for pods and services. Calculate here to ensure they do not overlap with your node network.
Firewall rule creation
Verifying whether a specific IP address falls within a security group rule CIDR range. Use the same-subnet check here.
Network documentation
Generate accurate subnet documentation with network address, broadcast address, and usable host range for your network diagrams.
💡 Pro Tips for Accurate Results
Subnet mask to CIDR. 255.255.255.0 = /24. 255.255.0.0 = /16. The CIDR prefix length is the count of consecutive 1-bits in the subnet mask.
First and last hosts are reserved. The first address is the network address; the last is the broadcast address. Neither is assignable to a host. A /24 has 254 usable host addresses (256 - 2).
AWS adds 3 more reserved. In AWS VPCs, the first 4 addresses and the last 1 in each subnet are reserved. A /24 in AWS has 251 usable IPs.
Same subnet check. IP1 & mask == IP2 & mask determines if two IPs are on the same subnet — the calculator shows this without manual AND operations.
🔗 Use These Together
🏁 Bottom Line
Subnet calculations underpin VPC design, network configuration, and firewall rules. This calculator handles the bit arithmetic automatically. For CIDR notation: CIDR Calculator. For network bandwidth: Bandwidth Calculator.