ToolKitHive
Back
networking

Subnet Calculator

Calculate network range, broadcast address, and usable hosts from IP/CIDR.

Subnet Calculator

Calculate network range, broadcast address, and usable hosts from IP/CIDR.

Subnet Calculator β€” CIDR & IP Subnet Mask Calculator Online for Free

Whether you are configuring a home network, designing a corporate infrastructure, or studying for a networking certification, subnetting is one of the most essential skills in IT. Our free Subnet Calculator takes any IP address with CIDR notation and instantly computes the network address, broadcast address, subnet mask, wildcard mask, usable host range, and host count. Live calculation as you type β€” no buttons needed.

What Is Subnetting?

Subnetting is the practice of dividing a large IP network into smaller, more manageable sub-networks (subnets). This improves network performance, enhances security, and conserves IP addresses.

Every IPv4 address is 32 bits, typically written as four decimal octets (e.g., 192.168.1.0). A subnet mask defines which bits represent the network and which represent hosts. CIDR notation appends the number of network bits to the IP address with a slash β€” for example, 192.168.1.0/24 means the first 24 bits are the network portion and the remaining 8 bits are for hosts.

CIDR Subnet Mask Addresses Usable Hosts
/24 255.255.255.0 256 254
/25 255.255.255.128 128 126
/26 255.255.255.192 64 62
/27 255.255.255.224 32 30
/28 255.255.255.240 16 14
/29 255.255.255.248 8 6
/30 255.255.255.252 4 2
/16 255.255.0.0 65,536 65,534
/8 255.0.0.0 16,777,216 16,777,214

How to Use the Subnet Calculator

  1. Enter an IP address with CIDR notation β€” for example, 192.168.1.0/24. If you omit the CIDR suffix, /24 is assumed.
  2. Or pick a common preset β€” Home (/24), Small (/28), Point-to-Point (/30), Class C (/16), Class B (/8).
  3. Results appear instantly β€” network address, broadcast, subnet mask, wildcard mask, first and last usable host, total addresses, usable hosts, CIDR notation, IP class, and binary subnet mask.
  4. Copy any value β€” click the copy icon next to any result to copy it to your clipboard.

Key Features

Feature Description
Live Calculation Results update as you type β€” no button needed
CIDR Notation Input Enter IP/prefix format (e.g. 10.0.0.0/8)
Common Presets One-click for typical subnet sizes
Full Subnet Details Network, broadcast, mask, wildcard, hosts, range
Binary Mask Display See the subnet mask in binary notation
IP Class Detection Automatically identifies Class A, B, C, D, or E
Copy Any Value One-click copy for every result field

Common Use Cases

Network Design and Planning

When designing a network, you need to determine the correct subnet size for each segment. A /24 gives 254 hosts, a /28 gives 14. This calculator helps you choose the right CIDR for each VLAN or subnet.

Firewall and Router Configuration

Firewall rules, access control lists, and route statements often require subnet masks in different formats. This calculator provides the subnet mask, wildcard mask, and CIDR notation so you can copy the format your device expects.

IP Address Allocation

When assigning IP ranges to departments, buildings, or services, you need to know exactly where each subnet starts and ends. The network and broadcast addresses define the boundaries.

Cisco and Networking Certification Study

CCNA, CompTIA Network+, and similar certifications require you to subnet quickly and accurately. This tool helps you verify your manual calculations while studying.

Cloud Infrastructure Setup

AWS VPCs, Azure Virtual Networks, and GCP subnets all require CIDR notation. Before creating a cloud subnet, verify the address range and host count with this calculator.

Troubleshooting Network Issues

When two devices cannot communicate, checking whether they are in the same subnet is one of the first diagnostic steps. Enter both IPs and verify they share the same network address.

Tips and Best Practices

  • Always reserve room for growth. If a department currently needs 30 IPs, allocate a /26 (62 hosts) rather than a /27 (30 hosts) to avoid re-subnetting later.
  • Use /30 for point-to-point links. Router-to-router connections only need two usable addresses. A /30 provides exactly that.
  • Remember that /31 is special. RFC 3021 allows /31 for point-to-point links with no network or broadcast address. This calculator handles it correctly.
  • The wildcard mask is the inverse of the subnet mask. Cisco ACLs use wildcard masks. For a /24 (mask 255.255.255.0), the wildcard is 0.0.0.255.
  • Network and broadcast addresses are not usable. In subnets larger than /31, the first address is the network identifier and the last is the broadcast. Usable hosts are everything in between.

Frequently Asked Questions

Is this Subnet Calculator free?

Yes. The tool is completely free with no usage limits, no registration, and no hidden costs.

Does it support IPv6?

This calculator supports IPv4 only. IPv6 uses a different addressing scheme with 128-bit addresses and different subnetting conventions.

What is CIDR notation?

CIDR (Classless Inter-Domain Routing) notation expresses a subnet as an IP address followed by a slash and the number of network bits. For example, 192.168.1.0/24 means the first 24 bits are the network portion. It replaced the older classful addressing system.

What is the wildcard mask?

The wildcard mask is the bitwise inverse of the subnet mask. For a /24 (subnet mask 255.255.255.0), the wildcard mask is 0.0.0.255. It is used primarily in Cisco access control lists and OSPF configuration.

What is the difference between total addresses and usable hosts?

Total addresses is the full size of the subnet (2^(32 - CIDR)). Usable hosts subtracts the network address and broadcast address, giving 2 fewer. For a /24: 256 total addresses, 254 usable hosts.

What happens with /31 and /32 subnets?

A /31 subnet (RFC 3021) has 2 addresses with no dedicated network or broadcast, so both are usable for point-to-point links. A /32 represents a single host β€” commonly used for host routes and loopback addresses.

enptesdejafrruitnltrarzh