b2KIT

Subnet Calculator

Calculate IP subnet details including network address, broadcast address, host range, and CIDR notation.

Tested tool guide Tested browser tools Checked August 16, 2026

What Subnet Calculator does, with a checked example

Enter an IPv4 address and a prefix length, and this tool returns the facts that define the subnet containing that address: the network address, the broadcast address, the usable host range, and the same mask written as CIDR notation. Everything follows from one bit-level rule - the prefix fixes how big the block is, and the address you typed only decides which block you are in. The surprise most people hit: the subnet does not start at the address they entered, and the usable host count is always two less than the block size.

Worked example

A concrete input and expected output from the current implementation.

Input

192.168.1.37/26

Expected output

Network address: 192.168.1.0
Broadcast address: 192.168.1.63
Usable host range: 192.168.1.1 - 192.168.1.62
Usable hosts: 62
Netmask: 255.255.255.192 (/26)

A /26 prefix fixes the block at 64 addresses (2^(32-26)), and 37 falls inside the block that starts at 192.168.1.0 and ends at 192.168.1.63. The first and last addresses are reserved as network and broadcast, leaving 62 usable addresses.

How the result is produced

1

Deriving the subnet values

The prefix length is the number of leading bits every address in the block shares. The tool aligns the address you entered to that boundary: the network address is the block's first address, the broadcast address is its last, and the usable range sits between them. Block size is 2^(32 - prefix), so each prefix one bit shorter doubles the block.

2

Reading the output set

Each result is paired with its meaning: network address, broadcast address, the usable host range between them, and the mask written both as a /prefix and as a dotted-decimal mask. Two prefixes break the usual pattern: a /31 uses both addresses for hosts on point-to-point links (RFC 3021), and a /32 describes one single host.

Good uses

  • Sizing a new VLAN or office network: 10 devices fit a /28 (14 usable), 30 devices need a /27 (30 usable). The tool turns that arithmetic into the exact range to hand to DHCP.
  • Debugging why a host cannot reach its gateway: a workstation at 192.168.1.70/26 and a gateway at 192.168.1.1/26 look adjacent, but the tool shows the host is in 192.168.1.64/26 while the gateway is in 192.168.1.0/26 - different subnets, so traffic never leaves the host.
  • Converting dotted-decimal masks in firewall rules and route tables: pasting 255.255.255.240 yields /28 with a precise 16-address range to copy into ACLs, allowlists, or summarization notes without counting by hand.

Limits and checks

  • Usable hosts are not the block size. A /28 block holds 16 addresses but reports 14 usable hosts; the first and last are reserved as network and broadcast. If you need 15 device addresses, a /28 is one short and you actually need a /27.
  • The address you entered can itself be unusable. The tool resolves the subnet that contains the address, which is not a guarantee the address is assignable: 192.168.1.63/26 is in the range on paper but is that block's broadcast address and cannot be assigned to a device.
  • The result describes one block at one prefix. It does not carve the block into smaller subnets, and it makes no judgment about whether the range is private (RFC 1918) or routable on the internet - treat the output as geometry, not policy.

Common questions

Why does it say 62 usable hosts for a /26 when the block clearly holds 64 addresses?

Because the first and last addresses are reserved, not merely discouraged. The network address identifies the block itself and the broadcast address reaches every host in it, so neither can belong to a device. Usable count is always block size minus two - 62 for a /26, 14 for a /28 - with /31 and /32 as the exceptions.

Does this work for IPv6?

The outputs the tool produces - network address, broadcast address, usable host range - are IPv4 concepts. IPv6 has no broadcast address, uses 128-bit addresses in a different notation such as 2001:db8::1/64, and counts hosts differently. If your task is IPv6 planning, use a calculator that states IPv6 support rather than assuming this one extends to it.

References and verification

The example and behavioral notes were checked against the browser implementation. Standards and primary references below define the relevant format, formula, or platform behavior.

Related Tools