Skip to calculator
Veomark

Free · Instant · No signup

IP Subnet & CIDR Calculator (IPv4 / IPv6)

IPv4 network, broadcast, host count, and mask from an address and prefix length.

Page updated 2026-09-04.

IP Subnet & CIDR Calculator (IPv4 / IPv6) visual
Sponsored

Calculator

Dotted quad.

CIDR 0-32. Default 24.

Calculated Results

Usable hosts

--

Sponsored

From an address and prefix to the full subnet picture

192.168.1.42/24 sits in the network 192.168.1.0, with broadcast address 192.168.1.255, subnet mask 255.255.255.0, and 254 usable host addresses (256 total addresses in the /24 block, minus the network and broadcast addresses, which can't be assigned to a host).

The /24 prefix means the first 24 bits (three full octets: 192.168.1) are fixed as the network portion, leaving the last 8 bits free for host addresses -- exactly why a /24 always has 256 total addresses (2^8) and 254 usable ones.

Every address from 192.168.1.1 through 192.168.1.254 in this block belongs to the same broadcast domain and can communicate directly at the link layer without routing -- 192.168.1.42 is just one specific host address within that range, not a special or fixed reference point.

Why network and broadcast addresses aren't usable

IPv4 integer math in the browser. IPv6 is not calculated here. The network address (all host bits zero, 192.168.1.0 here) identifies the subnet itself, and the broadcast address (all host bits one, 192.168.1.255) is reserved for sending to every host on that subnet simultaneously -- neither can be assigned to an individual device, which is why usable hosts is always 2 less than the block's total address count.

Smaller prefixes (like /28 or /30) follow the identical math at a smaller scale -- a /30 has exactly 4 total addresses and only 2 usable hosts, which is why /30 is a common choice for point-to-point links that only ever need two endpoints.

This calculator handles IPv4 only. IPv6 subnetting uses a much larger address space and different conventions (no broadcast address at all, since IPv6 uses multicast instead) that a straightforward IPv4 bitmask calculation doesn't extend to.

Related IP and networking tools

To see the same IPv4 address in hex, binary, and unsigned-integer form instead of subnet boundaries, the IP Address Hex/Binary Converter covers that conversion.

For the port a service listens on within this network, rather than the address range itself, the Port Number Lookup Guide is the companion reference.

Frequently Asked Questions (FAQ)

How is 254 usable hosts calculated for a /24?

A /24 leaves 8 bits for host addressing, giving 2^8 = 256 total addresses. Subtracting the network address (192.168.1.0) and broadcast address (192.168.1.255), which can't be assigned to hosts, leaves 254 usable addresses.

Why can't a device be assigned the network or broadcast address?

The network address (all host bits zero) identifies the subnet as a whole rather than any single device, and the broadcast address (all host bits one) is reserved for messages meant to reach every host on the subnet at once -- both are structural, not assignable, addresses.

Does this calculator support IPv6?

No. IPv4 integer math in the browser. IPv6 is not calculated here. It performs IPv4-specific bitmask arithmetic. IPv6 subnetting works differently (a vastly larger address space and no broadcast address, since IPv6 uses multicast instead), which this tool doesn't handle.

What does a smaller prefix like /30 change about usable hosts?

A /30 leaves only 2 host bits, giving 4 total addresses and 2 usable hosts after subtracting network and broadcast -- which is why /30 is a common choice specifically for point-to-point links that only need exactly two endpoints.

Is 192.168.1.42 significant, or just an example host in the block?

It's just an example host address within the 192.168.1.0/24 range -- any address from .1 through .254 in that block would produce the identical network, broadcast, mask, and usable-host results, since those depend only on the prefix length, not the specific host address entered.