Copied!
Sign In
Access your IPWhois.net account
No account? Create one

IP Subnet Calculator

or Subnet Mask overrides prefix selection

Common IPv4 Subnet Reference

Click Calculate on any row to run it through the calculator.

CIDR Subnet Mask Total Usable Typical Use
/30 255.255.255.252 4 2 Point-to-point router links
/29 255.255.255.248 8 6 Small remote sites or DMZ
/28 255.255.255.240 16 14 VoIP or printer groups
/27 255.255.255.224 32 30 Small office departments
/26 255.255.255.192 64 62 Medium-sized workgroups
/25 255.255.255.128 128 126 Larger teams or guest Wi-Fi
/24 255.255.255.0 256 254 Standard local area networks
/23 255.255.254.0 512 510 Two merged /24 networks
/22 255.255.252.0 1,024 1,022 Medium enterprise segments
/20 255.255.240.0 4,096 4,094 Large enterprise or campus LAN
/16 255.255.0.0 65,536 65,534 Campus or enterprise-wide
/8 255.0.0.0 16,777,216 16,777,214 Major ISP allocations (Class A)

Understanding Subnetting and CIDR

A subnet divides an IP address space into smaller, more manageable segments. Each subnet has a network address (the first address in the block, used to identify the subnet itself), a broadcast address (the last address, used to send messages to all hosts in the subnet), and a range of usable host addresses between them.

CIDR notation (Classless Inter-Domain Routing) expresses the subnet mask as a prefix length appended to the IP address with a slash. A /24 means the first 24 bits are the network portion and the remaining 8 bits can be assigned to hosts, giving 256 total addresses (254 usable). A /25 splits that in half. Each bit you add to the prefix doubles the number of subnets and halves the host count per subnet.

The wildcard mask is the binary inverse of the subnet mask and is used in access control lists (ACLs) on Cisco devices and in OSPF configurations to specify which bits of an address to match. A /24 wildcard is 0.0.0.255, meaning the first three octets must match exactly and the last octet can be anything.

IPv6 Subnetting Basics

IPv6 uses 128-bit addresses, making the arithmetic different but the concepts the same. The standard subnet size for a single LAN is a /64, which leaves 64 bits for interface identifiers and is required for SLAAC (Stateless Address Autoconfiguration). ISPs typically assign a /48 or /56 to a customer site. A /48 contains 65,536 possible /64 subnets, which is more than enough for any organisation.

IPv6 does not use broadcast addresses. It uses multicast groups for equivalent functionality. The "last address" shown in the IPv6 results is the highest address in the prefix, not a broadcast. There is also no meaningful concept of "wasting" IPv6 addresses, since the address space is so large that even assigning a /64 to each point-to-point link leaves virtually the entire space untouched.

Frequently Asked Questions

What is the difference between a subnet mask and a wildcard mask?

A subnet mask uses 1s to mark the network bits and 0s to mark the host bits (255.255.255.0 for a /24). A wildcard mask is the binary inverse: 0s for bits that must match and 1s for bits that can vary (0.0.0.255 for a /24). Subnet masks are used to calculate network addresses; wildcard masks appear in ACLs and routing protocol configurations.

What is the network address and can I assign it to a device?

No. The network address is the first address in a subnet and identifies the subnet itself in routing tables. The broadcast address is the last and is reserved for subnet-wide communication. This is why the usable host count is always two less than the total address count, for any prefix shorter than /31.

What does the binary representation show?

The binary view shows your IP address and subnet mask in raw binary form. Where the mask has a 1, that bit is part of the fixed network portion. Where it has a 0, that bit belongs to the host and can vary. ANDing the IP and mask always gives you the network address regardless of which host address in the subnet you started with.

How do I split a /24 into smaller networks?

Increase the prefix length. Each extra bit borrowed doubles the number of subnets and halves the hosts per subnet. A /24 split to /25 yields two subnets of 128 addresses; to /26 yields four of 64; to /30 yields 64 subnets of 4 addresses (2 usable). The /30 subnet table in the results shows all 64 networks within the /24 supernet and highlights which one your IP belongs to.

What is 6to4 addressing?

6to4 (RFC 3056) embeds a 32-bit IPv4 address into an IPv6 prefix, allowing IPv6 traffic to tunnel over IPv4 infrastructure. The prefix is always 2002::/16 followed by the IPv4 address in hex. It is largely deprecated in favour of native dual-stack, but the prefix is shown here for completeness.