CIDR Subnet Calculator

Enter an IP address with CIDR notation to instantly calculate the network address, broadcast, subnet mask, usable host range, host count and wildcard mask.

Last updated: 2026/10/16 Developer Feedback & bug reports
Input

Enter an IP address with CIDR (e.g. 192.168.1.0/24).

How to Use

1

Enter IP/CIDR

Enter the IP address and prefix length in CIDR notation (e.g. 192.168.1.0/24). You can also pick the prefix length from the menu.

2

View Results

As you type, the network address, broadcast, subnet mask, usable host range and more are calculated automatically.

3

Copy the Results

Click the copy button next to any value to copy it to your clipboard, ready to paste into your configs or docs.

About CIDR / Subnet Calculation

CIDR (Classless Inter-Domain Routing) describes a network range by combining an IP address with a prefix length, such as "192.168.1.0/24". This tool takes that notation and automatically calculates the network address, broadcast address, subnet mask, wildcard mask, and the range and number of usable host addresses. It is handy for network design, configuring routers and firewalls, and for learning. All calculations run inside your browser and your input is never sent to any server.

Features

  • Real-time CalculationNetwork details are computed instantly as you type. No waiting for results.
  • Comprehensive OutputNetwork, broadcast, mask, wildcard, host range and host count are all listed at once.
  • IPv4 & Basic IPv6In addition to detailed IPv4 math, it computes IPv6 prefix, network and total address count.
  • Fully Client-sideEvery calculation happens on your device. The addresses you enter are never sent to a server.

Use Cases

  • Subnet configuration for routers, switches and firewalls
  • Planning CIDR ranges for cloud VPCs and subnets
  • Checking DHCP scopes and usable host counts
  • Building wildcard masks for access control lists (ACLs)
  • Studying networking and preparing for certifications

Related Tools & Guides

FAQ

What is the difference between CIDR and a subnet mask?
Both express the length of the network portion, but use different notations. CIDR uses a prefix length such as "/24", while a subnet mask uses four octets such as "255.255.255.0". This tool calculates the matching subnet mask from the CIDR you enter.
How is the number of usable hosts calculated?
In general it is "2^(32 − prefix length) − 2". The −2 excludes the network address and the broadcast address. Note that /31 is treated as 2 hosts (RFC 3021 point-to-point) and /32 as 1 host.
What is a wildcard mask?
It is the inverse (bit-flipped) of the subnet mask, mainly used in Cisco ACLs. For example, the wildcard for the subnet mask 255.255.255.0 is 0.0.0.255.
Can it tell whether an address is private?
Yes. It detects the private ranges 10.0.0.0/8, 172.16.0.0/12 and 192.168.0.0/16, as well as loopback, link-local and others, and shows the result as the "Type".
Is the IP address I enter sent anywhere?
No. All calculations happen entirely in your browser with JavaScript. The IP addresses and CIDR you enter are never sent to or stored on any server.
Does it support IPv6?
IPv6 is supported in a basic way. It shows the compressed and expanded address, the prefix length, the network prefix and the total address count. Detailed host math is optimized for IPv4.
How should I think about splitting a subnet further?
Each time you increase the prefix length by one bit, the network is split into two subnets and the number of usable hosts per subnet is roughly halved. The "Subnet Split Guide" in this tool summarizes, for the IPv4 network you entered, how many subnets and usable hosts you get when dividing it from /+1 to /+4.
What is the binary subnet mask view useful for?
In the binary view, the leading consecutive 1s of the subnet mask represent the network portion and the 0s represent the host portion. This makes the relationship between the prefix length and each octet boundary easy to see, which helps when learning networking or confirming why a given host count results.