IP Subnet Calculator

Calculate an IPv4 subnet from an address and CIDR prefix or subnet mask. The result shows the network boundary, broadcast address, host capacity, and any address usage warnings.

Enter a CIDR prefix with the address, such as 192.168.1.10/24, or choose the matching CIDR and subnet mask from the list.

Need to calculate an IPv6 prefix?

IP Prefix Calculator

Entering an IPv4 Address and Network Size

Enter an IPv4 address with a CIDR suffix, such as 192.168.10.77/26, or enter the address alone and choose a value from CIDR / Subnet mask. Each option pairs a prefix length with its equivalent dotted-decimal mask. Select Calculate Subnet to generate the result.

The address does not have to be the first address in the subnet. The calculator determines the containing network from the address and prefix. If you provide a prefix in the address and also choose one from the list, they must agree; conflicting values produce an error rather than an assumed network size.

The prefix specifies how many of the address's 32 bits identify the network. The remaining bits determine the number of addresses in the block. Increasing the prefix length by one halves that number, while decreasing it by one doubles it. A larger slash number therefore describes a smaller block, not a larger one.

A Subnet Example with /26

For 192.168.10.77/26, the network is 192.168.10.64/26 and the subnet mask is 255.255.255.192. The block contains 64 addresses, from 192.168.10.64 through 192.168.10.127. On a conventional subnet of this size, the first address identifies the network and the last is its directed broadcast address.

The usable host range is 192.168.10.65 through 192.168.10.126, giving 62 possible host addresses. The entered address, 192.168.10.77, lies inside that range. Entering another address from the same block with /26 returns the same network boundaries.

These calculated values describe a network, not the settings currently applied to your router. The calculator does not know which of the 62 addresses are already assigned, reserved by DHCP, or needed for infrastructure. Keep your actual allocation records alongside the calculation when planning a change.

Reading the Network Setup Values

The first result group collects the values most useful for checking an IPv4 subnet: its CIDR network, subnet mask, host range, broadcast address, and host capacity. Read the labels as well as the numbers. A result described as a calculated host range is not necessarily an address pool suitable for ordinary devices.

The additional network details show the original input, normalized CIDR notation, network address, total addresses, network bits, and host bits. The address type describes the entered address, while the CIDR range status evaluates the block's permitted use. A large block can span several address categories, even when the entered address belongs to just one of them.

The historical IP class is included for reference. The selected prefix, not the old class boundary, controls this calculation. Do not replace a chosen /26 with /24 just because the first part of an address resembles an example from classful addressing.

Understanding /31 and /32 Results

A /31 block has two addresses. On a point-to-point link that supports /31 addressing, both addresses can be used without reserving a separate directed broadcast address. The calculator identifies this case instead of subtracting two from the total address count.

A /32 identifies one IPv4 address. It is a host route rather than a conventional subnet with separate network, host range, and broadcast roles. The result reflects that single address and does not invent a broadcast address outside it.

The special handling of these prefix lengths does not cancel address usage restrictions. A /31 inside a reserved range remains subject to that range's purpose. Likewise, calculating a public /32 does not establish that the address has been assigned to you.

When the Range Is Not an Ordinary Host Pool

The calculator distinguishes private and public unicast ranges from blocks reserved for other purposes. A block can contain documentation addresses, multicast addresses, shared space for internet providers, or a mixture of uses. In those cases, a warning explains why the mathematical capacity should not be treated as a general pool for your devices.

For a mixed block, calculate the smaller range actually allocated to your network. Simply choosing a broad prefix around an address can include many unrelated or reserved ranges. The arithmetic remains useful for understanding boundaries, but it does not give permission to configure the entire block.

Using Masks and Alternate Representations

The wildcard mask is the bitwise inverse of the subnet mask. The result also includes binary forms, the IPv4 integer value, a hexadecimal value, a reverse DNS name, and an IPv4-mapped IPv6 representation. These are alternate views of the address or mask, not discoveries about services running on the network.

The reverse DNS name is constructed from the entered IPv4 address. It does not prove that a PTR record exists. Similarly, the mapped IPv6 value is a representation of the IPv4 input, not evidence that the connection supports IPv6.

Viewing and Copying Address Lists

For ranges suitable for ordinary host assignment, the address list runs from the first usable address to the last. JavaScript displays larger lists in pages of up to 4,096 addresses. The page controls move through that calculated range; they do not scan the addresses or contact devices.

The entire list can be copied when it fits within the supported copy limit of 4,096 addresses. For larger lists, copy the displayed portion. The separate Copy Calculation Results control copies the summary and detail values rather than every address in the list.

If JavaScript is unavailable, the calculated boundaries and counts remain in the result even though the interactive address list cannot be shown. Use those summary values to confirm the network size before working with a large list elsewhere.

IP Subnet Calculator (FAQ)