Skip to content

Convert a CIDR block to its IP address range

Find the exact boundaries of one network without splitting it. Enter either IPv4 or IPv6 CIDR notation; the converter normalizes host bits and reports the inclusive range and exact address count.

Inclusive range versus usable-host range

For 192.0.2.129/26, the containing network is 192.0.2.128/26. Its inclusive range is 192.0.2.128 through 192.0.2.191, containing 64 addresses. On a conventional IPv4 LAN the usable-host range is 192.0.2.129 through 192.0.2.190; the last address is broadcast.

An IPv4 /31 has two endpoint addresses for a point-to-point link, and a /32 has one address. The converter displays these exceptions rather than blindly subtracting two. For IPv6 it reports mathematical boundaries and does not label the last address as broadcast.

How boundaries are calculated

The first address is the input address AND the prefix mask. The final address is that network address plus 2^(W − p) − 1, with W = 32 or 128. This includes both endpoints. Supplying a host address instead of an aligned network address therefore produces the containing block.

For example, 2001:db8::1/126 normalizes to 2001:db8::/126 and ends at 2001:db8::3, a range of four addresses. IPv6 values use 128-bit integer arithmetic, including /0 and /128, so the range cannot lose precision to floating-point rounding.