Back to Utiliverse
Utiliverse Guides

All guides / Networking

CIDR & Subnet Masks Explained

Understand CIDR prefix lengths, IPv4 subnet masks, /31 and /32 special cases, IPv6 prefixes, and when subnet math is the right layer to investigate.

By UtiliverseLast reviewed: October 9, 2026

A prefix is an address boundary

In 192.168.10.77/26, the /26 means that the first 26 bits identify the IPv4 network. Six bits remain, giving 64 addresses in the block. The dotted-decimal mask is another representation of the same boundary: 255.255.255.192. A larger prefix number gives a smaller address block. CIDR is described in RFC 4632.

Think of the calculation as identifying the block containing an address. It does not discover the configuration of a router. If you enter the wrong prefix, the arithmetic can be internally correct while describing the wrong network.

Try the math directly: use the IP Subnet Calculator to enter an IPv4 or IPv6 address and prefix, then compare the calculated network boundary with the configuration you expect.

Worked example: a /26 office segment

Use 192.168.10.77 with prefix /26 in the calculator. The last-octet block boundaries are 0, 64, 128, and 192. Because 77 lies between 64 and 127, the network is 192.168.10.64/26.

Expected results for 192.168.10.77/26
OutputValue
Network192.168.10.64
Broadcast192.168.10.127
Conventional host range192.168.10.65–192.168.10.126
Total / usable64 / 62
Mask / wildcard255.255.255.192 / 0.0.0.63

For 50 planned devices, 62 conventional addresses leave 12 before your own reservations. Account for gateways, infrastructure, growth, and platform-specific reserved addresses before deciding that the block is large enough. A cloud provider may reserve more addresses than this generic calculation.

Why /31 and /32 need different interpretation

The familiar “subtract two” rule describes conventional IPv4 subnets; it is not universal. A /31 has two endpoint addresses on supported point-to-point links, as specified in RFC 3021. A /32 describes a single address or host route. Neither should be treated as an ordinary multi-host LAN with a broadcast address.

The calculator labels these special cases explicitly. Before applying /31 to equipment, confirm that both ends and the intended interface type support it. Numerical capacity alone is not an interoperability test.

IPv6 capacity is a different calculation

IPv6 has 128 bits. A /64 therefore contains 2^64 addresses, and IPv6 does not use IPv4-style broadcast. For example, 2001:db8:abcd:1234::42/64 normalizes to 2001:db8:abcd:1234::/64. The documentation prefix in this example is for explanation, not deployment. See RFC 4291.

The current tool accepts hexadecimal IPv6 notation, including compressed groups. It does not accept IPv4-embedded dotted notation as an IPv6 input. Use an equivalent hexadecimal representation. A displayed capacity is not a recommendation to allocate every address or use a particular prefix on every interface.

When CIDR Math Is—and Is Not—the Problem

CIDR calculations answer addressing questions: which network contains an address, where the boundary falls, what mask corresponds to a prefix, and how large the address block is. They do not prove that two devices can communicate.

Choose the next layer after subnet math
If the question is…Use this next
Does this IP belong to the expected subnet?IP Subnet Calculator
Why does a hostname not resolve?DNS and Network Troubleshooting
Which TCP or UDP port should this service use?TCP vs UDP Ports guide or Port Checker
Why is communication failing even though the subnet is correct?Check VLANs, routing, firewall policy, interface configuration, and then the application layer.

Check a plan before changing a network

  1. Write down the actual address and prefix from the intended interface configuration.
  2. Calculate the normalized network and its boundaries.
  3. Compare the entire range with neighboring subnets and VPN routes; different starting addresses can still overlap.
  4. Verify DHCP scope, gateway, static reservations, routing, and firewall assumptions separately.
  5. Keep the previous configuration available and test connectivity after an approved change.

Two addresses in the same calculated subnet do not prove that their devices can communicate. VLAN isolation, routing, host firewalls, and duplicate addresses can still prevent traffic. Use the IP Subnet Calculator to check the addressing premise, then investigate the next layer with the DNS and Network Troubleshooting guide or TCP vs UDP Ports guide as appropriate.

Try the related tools

  • IP Subnet Calculator — calculate IPv4/IPv6 prefixes, ranges, masks, and host capacity.
  • Port Checker — look up common TCP/UDP service assignments after the addressing layer is confirmed.

Continue reading

Sources and review

Examples are illustrative. Reviewed October 9, 2026 against the listed references and the related tool behavior. Methodology · Report a correction.