A subnet calculator is useful for checking work, but the result becomes much more valuable when you can explain the boundary. The calculator below shows both the answer and the steps that produced it.

Calculate an IPv4 subnet

Use CIDR notation in the first field, or enter a plain IPv4 address and supply the prefix or dotted-decimal mask in the second field.

Examples: 192.168.40.77/26 or 192.168.40.77

Optional when the first field includes CIDR. Examples: /26, 26, or 255.255.255.192

How to read the results

The network address is the first address in the calculated block. Under traditional IPv4 subnetting, it identifies the subnet rather than an endpoint. The broadcast address is the last address and reaches every host in that local broadcast domain when directed broadcast behavior is supported.

The first and last usable addresses sit between those boundaries. A router interface does not have to use the first usable address, even though labs and diagrams often place the default gateway there. The address plan decides which usable address belongs to each device.

The wildcard mask is the bitwise inverse of the subnet mask. A mask bit of 1 becomes 0, and a mask bit of 0 becomes 1. Wildcard masks appear in technologies such as access control lists and some routing configurations.

The status describes the entered address, not every address in the calculated block. A private result means the input falls within an RFC 1918 range. Documentation results belong to TEST-NET blocks intended for examples. Public means the calculator did not match a listed special-purpose block. It does not confirm ownership or prove that the address is reachable from the internet.

What the calculator is doing

IPv4 contains 32 bits. The CIDR prefix tells the calculator how many leading bits belong to the network portion. A /26 fixes 26 bits and leaves 6 host bits.

The total number of addresses is:

2^(host bits)

For a /26, that is 2^6 = 64. Traditional subnetting reserves the first and last addresses as the network and broadcast addresses, leaving 62 usable host positions.

The network address is calculated with a bitwise AND:

IPv4 address AND subnet mask = network address

The broadcast boundary is calculated by combining the network address with the wildcard mask. The binary table exposes those octets so you can see which bits remain fixed and which bits vary inside the block.

For practice without relying on the calculator, use the IPv4 Subnetting Reference. It covers powers of two, borrowed bits, block sizes, VLSM, special ranges, and worked examples.

How /31 and /32 results differ

A /31 contains two addresses. RFC 3021 permits both addresses to serve as endpoints on a point-to-point link, so the usual subtraction for a network and directed broadcast address is not applied. This calculator reports both endpoint addresses and states that no directed broadcast is used for that design.

A /32 contains one address. It is commonly used as a host route or to identify one interface address. There is no separate broadcast address, and the first and last address are the same.

Those cases depend on context. A /31 is appropriate for supported point-to-point links, not a normal multi-access LAN that needs ordinary broadcast behavior.

What this calculator does not verify

The result is mathematical. It does not query routing tables, DHCP scopes, address-management records, regional registries, or the current owner of a public address. It also does not determine whether a gateway, VLAN, firewall rule, or upstream route is configured correctly.

An address can fit the subnet math and still fail in the network. For example, two hosts may share a calculated prefix but belong to different VLANs. A valid host address may already be assigned to another device. A public-looking address may not be allocated or advertised. Use the calculation as one piece of evidence, then verify the actual network design.

IPv4 Subnetting Reference Learn CIDR blocks, host counts, borrowed bits, block-size shortcuts, special ranges, and worked examples. Domain 1: Networking Concepts Connect subnetting to addressing, traffic flow, devices, cloud networks, and troubleshooting clues. Domain 2: Network Implementation Apply prefixes to routes, VLAN gateways, subinterfaces, and implementation decisions. Network Troubleshooting Tools Quick Reference Match host commands, path tests, packet tools, and physical test equipment to the theory being tested. Network+ N10-009 Practice Test Apply subnetting and other networking concepts in randomized questions with detailed explanations. Network+ resource hub Find the full study guide, all five domains, quick reviews, acronyms, ports, and practice tests.