Subnet Calculator

Professional subnet calculator with CIDR notation, IP ranges, and comprehensive network analysis. Get instant results for network design and administration.

Enter any valid IP address (e.g., 192.168.1.0)
/24
CIDR prefix (0-32). Common: /24, /16, /8

CIDR Reference

Large Networks
/8 = 16,777,216 hosts (Class A)
/16 = 65,536 hosts (Class B)
/24 = 256 hosts (Class C)
Small Networks
/25 = 128 hosts
/26 = 64 hosts
/27 = 32 hosts
/28 = 16 hosts
/29 = 8 hosts
/30 = 4 hosts
Special Cases
/31 = 2 hosts (point-to-point)
/32 = 1 host (single IP)

About Subnet Calculator

Our professional subnet calculator provides comprehensive network analysis for IT professionals, network administrators, and students learning about computer networking. This tool performs complex calculations instantly, delivering accurate subnet information including network addresses, broadcast addresses, usable IP ranges, and detailed network characteristics.

Understanding CIDR Notation

Classless Inter-Domain Routing (CIDR) notation represents the number of bits used for the network portion of an IP address. For example, /24 means the first 24 bits are used for the network, leaving 8 bits for host addresses. This flexible addressing system replaced the rigid class-based system, allowing more efficient use of IPv4 address space.

Network Address Calculation

The network address is calculated by applying the subnet mask to the given IP address using a bitwise AND operation. This identifies the beginning of the subnet and cannot be assigned to individual devices. Our calculator automatically performs this calculation and displays the result in standard dotted-decimal notation.

Broadcast and Usable Addresses

Every subnet has a broadcast address (the last address in the range) used to send messages to all devices in the network. The usable IP addresses are all addresses between the network address and broadcast address, excluding these two. In /31 and /32 networks, special rules apply where there are no usable host addresses.

Subnet Mask and Wildcard Mask

The subnet mask separates the network portion from the host portion of an IP address. The wildcard mask is the inverse of the subnet mask and is commonly used in access control lists (ACLs) and routing protocols. Our calculator provides both formats for comprehensive network planning.

Frequently Asked Questions

What is a subnet calculator used for?

A subnet calculator helps network administrators divide large IP networks into smaller, more manageable subnetworks. It calculates network addresses, broadcast addresses, usable IP ranges, subnet masks, and other critical network information needed for proper network design and management.

How do you calculate subnet mask from CIDR?

CIDR notation like /24 represents the number of bits used for the network portion. To calculate the subnet mask, set the first 24 bits to 1 and the remaining 8 bits to 0 in binary, then convert to decimal. For /24, this gives 255.255.255.0. Our calculator automatically performs this conversion for any CIDR prefix.

What is the difference between network and broadcast addresses?

The network address identifies the subnet itself and cannot be assigned to devices. The broadcast address is used to send data to all devices in the subnet and also cannot be assigned. All addresses between these two (except in /31 and /32 networks) are usable for host devices.

How many IP addresses are in a /24 subnet?

A /24 subnet has 256 total IP addresses (2^(32-24)). However, only 254 are usable for devices because the first address is the network address and the last is the broadcast address. The usable range is from x.x.x.1 to x.x.x.254.

What are private IP address ranges?

Private IP ranges are 10.0.0.0/8 (Class A), 172.16.0.0/12 (Class B), and 192.168.0.0/16 (Class C). These addresses are reserved for internal networks and not routable on the internet. Our calculator automatically identifies when you're working with private IP ranges.

When should I use /31 and /32 subnets?

/31 subnets (2 IP addresses) are typically used for point-to-point links between routers. /32 subnets (1 IP address) are used for loopback interfaces or when assigning an IP to a specific host. These special cases have no usable host addresses as all addresses are either network or broadcast addresses.