Subnet Calculator
Calculate network address, broadcast address, usable hosts, and subnet mask from an IP and CIDR.
How this is calculated
Subnet mask = 32-bit mask from CIDR prefix. Network = IP AND mask. Broadcast = Network OR ~mask. Usable = 2^(32โprefix) โ 2.
Frequently Asked Questions About Subnet Calculator
A subnet calculator breaks down IP networks into usable address ranges. It calculates the network address, broadcast address, usable host addresses, and subnet mask from an IP address and CIDR prefix.
What is CIDR notation and how does it work?
CIDR (Classless Inter-Domain Routing) notation like /24 indicates how many bits are used for the network portion of an IP address. /24 means the first 24 bits are the network, leaving 8 bits for hosts. Higher numbers = smaller networks with fewer usable addresses.
What is the difference between network and broadcast addresses?
The network address is the first address in a subnet (used to identify the network itself). The broadcast address is the last address (used to send messages to all hosts in the network). Neither can be assigned to individual devices.
How many usable host addresses are in a /24 subnet?
A /24 subnet has 256 total addresses, but 2 are reserved (network and broadcast), leaving 254 usable host addresses. Formula: 2^(32 โ CIDR) โ 2. This is what determines how many devices can connect to that subnet.
What is a subnet mask and why is it important?
A subnet mask (like 255.255.255.0) separates the network portion from the host portion of an IP address. It determines which bits represent the network and which represent individual hosts. It's essential for routers and devices to determine network boundaries.
What are IP classes and are they still used?
Legacy IP classes (A, B, C) divided address space by fixed bit allocations. Class A: /8, Class B: /16, Class C: /24. Modern networking uses CIDR instead, which is more flexible and efficient. IP classes are mostly historical but still referenced.
Can I use this calculator for subnetting training?
Yes, absolutely. This calculator is excellent for learning subnetting concepts. Try different CIDR values (like /25, /26, /30) and observe how the usable host count changes. This helps build intuition for network design.