CIDR / Subnet Calculator

Enter an IP address in CIDR notation to calculate network details, binary breakdown, and subnet splits. Supports IPv4 and IPv6.

Examples: 10.0.0.0/8 · 192.168.1.0/24 · 172.16.0.0/12 · 10.10.10.0/28 · 2001:db8::/32

Divide a subnet into equal smaller subnets. Enter the parent CIDR in the Calculate tab first, then choose how many subnets to create.

IPv4 Subnet Reference (/8 – /32)

CIDRSubnet MaskWildcardHostsNetwork Class
Enter an IP address in CIDR notation (e.g., 192.168.1.0/24) and click Calculate.

How to Use the Subnet Calculator

  1. Enter CIDR notation — type an IP address followed by a slash and prefix length (e.g., 10.0.0.0/8 or 192.168.100.0/26) in the input field and click Calculate.
  2. Review results — the tool displays network address, broadcast address, subnet mask, wildcard mask, first and last usable host, total host count, and a binary breakdown of the IP and mask.
  3. Split a subnet — switch to the Split tab, enter the parent CIDR, choose how many equal subnets to divide it into, and get a table of all resulting subnets with their address ranges.
  4. Reference table — the Reference tab lists all prefix lengths from /8 to /32 with subnet mask, wildcard, and host count for quick lookup.

Understanding CIDR and Subnetting

CIDR (Classless Inter-Domain Routing) was introduced in 1993 to replace the old Class A/B/C address system and slow IPv4 exhaustion. In CIDR notation, the number after the slash (the prefix length) indicates how many bits belong to the network portion of the address. The remaining bits form the host portion. A /24 has 24 network bits and 8 host bits, accommodating 2^8 = 256 addresses, of which 254 are usable (network and broadcast addresses are reserved).

Private IP Address Ranges

RFC 1918 defines three ranges of private IPv4 addresses that are not routable on the public internet: 10.0.0.0/8 (16,777,216 addresses), 172.16.0.0/12 (1,048,576 addresses), and 192.168.0.0/16 (65,536 addresses). These are used extensively in home networks, enterprise LANs, cloud VPCs (AWS, Azure, GCP), Kubernetes pod networks, and Docker internal networks. Network Address Translation (NAT) allows these private addresses to communicate with the public internet through a single public IP.

How Subnetting Works in Cloud Networking

Cloud providers like AWS and Azure require you to plan your VPC (Virtual Private Cloud) CIDR blocks carefully because they cannot be resized after creation. A common pattern is to allocate a /16 VPC (65,534 hosts) and divide it into /24 subnets per Availability Zone and environment tier (public, private, database). For example: 10.0.1.0/24 for the public subnet in AZ-1, 10.0.2.0/24 for the private subnet in AZ-1, and so on. The Split tool on this page helps you plan such layouts by showing all subnets that result from dividing your VPC CIDR. Combine subnet planning with proper CORS headers for your API gateways to control cross-origin access.

IPv4 vs. IPv6 Subnetting

IPv6 uses 128-bit addresses written in hexadecimal groups (e.g., 2001:db8::/32). The same prefix-length concept applies, but the address space is so large that even a single /48 allocation (standard for an enterprise site) contains 2^80 addresses — more than the entire IPv4 space multiplied by itself billions of times. Common IPv6 prefix lengths: /32 for ISP allocations, /48 per site, /64 per subnet (required by SLAAC auto-configuration). This calculator handles basic IPv6 CIDR notation, showing the network prefix, address count, and prefix mask.

Frequently Asked Questions

CIDR (Classless Inter-Domain Routing) notation represents an IP address and subnet mask as IP/prefix. For example, 192.168.1.0/24 means 24 bits are the network portion, giving 256 total addresses (254 usable). CIDR replaced the old class-based system and allows more flexible address allocation.
The network address (all host bits 0) identifies the subnet and cannot be assigned to a host. The broadcast address (all host bits 1) is used to send packets to all hosts on the subnet — also not assignable. Usable hosts are all addresses in between, giving 2^(host bits) - 2 assignable addresses.
A /24 has 8 host bits: 2^8 = 256 total addresses, minus network and broadcast = 254 usable hosts. Other common values: /16 = 65,534, /25 = 126, /28 = 14, /30 = 2 (point-to-point), /32 = single host.
Subnetting divides a large network into smaller logical segments. Benefits: improved security by isolating network zones, reduced broadcast traffic, more efficient IP address use, and better organisation. Cloud VPCs, Kubernetes pods, and data centre networks all rely on subnetting.
A wildcard mask is the bitwise inverse of a subnet mask. For a /24 (mask 255.255.255.0), the wildcard is 0.0.0.255. Wildcard masks are used in Cisco ACLs and OSPF to specify which bits to match. A 0 bit means "must match", a 1 bit means "ignore".