Practical developer guides

IPv4 /31 and /32: host counts need context

Distinguish address-count arithmetic from point-to-point host semantics and deployment routing.

Nav Tools ·

Count addresses first

An IPv4 prefix p has 2 to the power 32 minus p addresses. A /31 contains two and a /32 contains one.

That arithmetic does not decide whether an address is usable in every network scenario.

192.0.2.10/31 → 192.0.2.10 and 192.0.2.11
192.0.2.10/32 → only 192.0.2.10

Apply the point-to-point exception

RFC 3021 permits both /31 addresses as host endpoints on supported point-to-point links. The usual subtract-two rule is not appropriate there.

For a shared LAN or a platform with different restrictions, check the implementation instead of applying the exception universally.

A /32 is a single-address route

A /32 commonly identifies one host address or route. It does not create a two-ended connected subnet by itself.

Routing, interfaces and next-hop configuration determine reachability. A subnet calculator cannot prove that a packet has a valid route.

Verify both boundaries and deployment rules

Use the calculator to inspect prefix, mask and range; test neighboring addresses against the CIDR.

Compare displayed usable-host assumptions with the target device documentation, especially for /31 and /32. Use documentation addresses in shared examples.

References

← Practical developer guides