ShadeKit.ioLoading…

Subnet Calculator

Calculate an IPv4 network and address range from a dotted-decimal address and CIDR prefix, including mask, wildcard and host-count interpretation.

Calculator arithmetic runs locally in your browser and does not require an API.

The interactive calculator loads here when JavaScript is enabled.

How to use Subnet Calculator

Enter four octets from 0 to 255 without leading zeros, plus a prefix from /0 to /32. The address may be inside the subnet; the tool calculates its network boundary. IPv6 is not supported.

Formula and method

An IPv4 address is a 32-bit value. Total addresses = 2^(32 − prefix). Network is the containing block’s lower boundary; wildcard is total − 1 and mask is 2^32 − total.

Understanding the results

For /0 through /30, conventional usable count is total minus network and directed broadcast. A /31 is interpreted as two endpoints on an RFC 3021 point-to-point link, without directed broadcast. A /32 is a single-address host route. These counts do not test reachability or guarantee real-world assignability.

Worked example

192.168.1.130/24 belongs to network 192.168.1.0 with mask 255.255.255.0 and wildcard 0.0.0.255. Broadcast is 192.168.1.255; the conventional range is .1 through .254, with 254 usable hosts out of 256 addresses.

IPv4 arithmetic only; this does not validate network configuration, security or connectivity.

References

Frequently asked questions

Why does /31 have two usable endpoints?

RFC 3021 treats both addresses as endpoints on a point-to-point link rather than reserving separate network and directed-broadcast addresses.

What does /32 mean?

It identifies one address. This tool reports one host and no separate directed broadcast.

Does this scan a network?

No. It performs address arithmetic locally and does not contact the entered IP address.