IP Subnet Calculator
Calculate IPv4 subnet details from CIDR notation, including network address, broadcast address, and usable host range. Free, instant.
Last updated:
Enter an address with a prefix or a mask: 10.0.0.1/16, 10.0.0.1/255.255.0.0 or 10.0.0.1 255.255.0.0. IPv6 works too: 2001:db8::/32.
| CIDR Notation | 192.168.1.0/24 |
| Network Address | 192.168.1.0 |
| Broadcast Address | 192.168.1.255 |
| First Usable Host | 192.168.1.1 |
| Last Usable Host | 192.168.1.254 |
| Subnet Mask | 255.255.255.0 |
| Wildcard Mask | 0.0.0.255 |
| Binary Mask | 11111111.11111111.11111111.00000000 |
| Total Hosts | 256 |
| Usable Hosts | 254 |
| IP Class (historical) | C |
| Address scope | Private (RFC 1918) |
| # | Subnet | Usable hosts |
|---|---|---|
| 1 | 192.168.1.0/26 | 192.168.1.1 – 192.168.1.62 |
| 2 | 192.168.1.64/26 | 192.168.1.65 – 192.168.1.126 |
| 3 | 192.168.1.128/26 | 192.168.1.129 – 192.168.1.190 |
| 4 | 192.168.1.192/26 | 192.168.1.193 – 192.168.1.254 |
| CIDR | Subnet Mask | Usable Hosts | Use case |
|---|---|---|---|
| /24 | 255.255.255.0 | 254 | Small LAN (254 hosts) |
| /23 | 255.255.254.0 | 510 | Medium LAN (510 hosts) |
| /22 | 255.255.252.0 | 1,022 | Office network (1022 hosts) |
| /16 | 255.255.0.0 | 65,534 | Large network (65534 hosts) |
| /28 | 255.255.255.240 | 14 | Small segment (14 hosts) |
| /30 | 255.255.255.252 | 2 | Point-to-point link (2 hosts) |
Click a row to load that prefix for the address you entered.
Was this tool useful?
Use the tool above and you can rate it here.
IP Subnet Calculator — Instantly Compute Network Address, Host Range, and Subnet Details
Subnetting is one of the fundamental skills in network engineering and cloud infrastructure work. Whether you are designing a VPC in AWS, configuring OSPF areas on a corporate network, writing ACL rules, or setting up a home lab, you need to quickly calculate the network address, broadcast address, usable host range, subnet mask, and wildcard mask for any given CIDR block. This calculator does all of that instantly from any IPv4 address in CIDR notation.
How to use this calculator
Enter any IPv4 address in CIDR notation — for example, 192.168.1.0/24 or 10.0.0.0/16 — or with a dotted mask such as 192.168.1.0 255.255.255.0. The calculator immediately shows the network address (first address in the subnet), broadcast address (last address), usable host range (first and last assignable IP addresses), subnet mask in dotted-decimal notation, wildcard mask (inverse of subnet mask, used in ACLs and OSPF), total number of addresses, number of usable hosts, IP address class (A, B, C, or special), and whether the address falls in a private range (RFC 1918) or public, and names the special ranges (loopback, link-local, carrier-grade NAT, documentation, multicast). Click any row in the common subnets reference table to load that prefix for the address you entered.
Understanding CIDR notation and subnet math
CIDR (Classless Inter-Domain Routing, defined in RFC 4632) notation expresses an IP address and its prefix length together — the /24 in 192.168.1.0/24 means the first 24 bits are the network prefix, leaving 8 bits for host addresses. With 8 host bits, there are 2^8 = 256 total addresses, minus 2 for the network and broadcast addresses, giving 254 usable hosts. A /16 gives 2^16 = 65,536 addresses (65,534 usable). A /30 gives 4 addresses (2 usable) — the minimum for a point-to-point link. The wildcard mask (e.g., 0.0.0.255 for a /24) is the bitwise inverse of the subnet mask and is used in Cisco ACL rules and OSPF network statements to specify which bits to match.
Who uses this tool
Network engineers use it when designing IP addressing schemes for enterprise networks or planning VPC CIDR ranges in cloud deployments. Systems administrators use it when configuring network interfaces and need to verify their subnet mask is correct. Security engineers use it when writing firewall ACL rules that require wildcard masks. Students studying for CCNA, CompTIA Network+, or AWS certifications use it to verify their manual subnetting calculations and build intuition for common subnet sizes.
Privacy and data handling
All subnet calculations are performed entirely in your browser using JavaScript bitwise operations — no IP addresses or network configurations are sent to any server.
Frequently asked questions
- What is CIDR notation?
- CIDR (Classless Inter-Domain Routing) notation expresses an IP address and its subnet mask together, e.g. 192.168.1.0/24. The number after the slash indicates how many bits are in the network prefix.
- What is the difference between network address and broadcast address?
- The network address is the first address in a subnet (all host bits = 0). The broadcast address is the last address (all host bits = 1). Neither can be assigned to a host.
- How are usable hosts calculated?
- Usable hosts = 2^(32−prefix) − 2. We subtract 2 for the network and broadcast addresses. A /30 has 4 total addresses and 2 usable hosts. A /31 has 2 addresses and both are usable on a point-to-point link (RFC 3021), and a /32 is a single host address.
- What is a wildcard mask?
- A wildcard mask is the inverse of the subnet mask. It is used in ACL rules and OSPF configuration to specify which bits to ignore. E.g., subnet mask 255.255.255.0 has a wildcard mask of 0.0.0.255.
- Which are private IP ranges?
- RFC 1918 defines three private ranges: 10.0.0.0/8, 172.16.0.0/12, and 192.168.0.0/16. Addresses in these ranges are not routable on the public internet. Other special ranges are not public either, and the calculator names them: loopback (127.0.0.0/8), link-local (169.254.0.0/16), shared carrier-grade NAT space (100.64.0.0/10), documentation, benchmarking, multicast and reserved ranges.
- Does the subnet calculator support IPv6?
- Yes. Enter an address with a prefix from 0 to 128, such as 2001:db8::/32. It shows the network and last address in compressed and expanded form (RFC 5952), the number of addresses and the kind of range (global unicast, unique local, link-local, documentation and so on). IPv6 has no broadcast address and none are given up to the network, so every address in the prefix can be assigned. A /64 is the normal size for one network and holds 18,446,744,073,709,551,616 addresses.
- How do I split a subnet into smaller ones?
- Enter the network, then pick a longer prefix in the Split into smaller subnets box. Each extra bit doubles the number of subnets: 192.168.0.0/24 split into /26 gives 4 subnets of 64 addresses, starting at 192.168.0.0, 192.168.0.64, 192.168.0.128 and 192.168.0.192. The table lists the first 128 subnets for IPv4 and the first 64 for IPv6 and always states the total, for example 4,294,967,296 /64 subnets in one /32.
From the blog
Related tools
- Unicode Converter
Convert text to Unicode code points and back, and inspect each character's UTF-8 byte sequence. Free, instant, no sign-up.
- Number Formatter
Format numbers for any locale — Indian lakh/crore, US thousands, European, and Arabic separators — instantly. Free, no sign-up needed.
- HTML Formatter & Beautifier
Format, beautify, and minify HTML instantly in your browser — clean up messy markup or shrink it for production. Free, no sign-up.
- CSS Box Shadow Generator
Generate CSS box-shadow values visually with a live preview, adjusting offset, blur, spread, and colour. Free, no sign-up needed.
- XML Formatter & Validator
Format, beautify, minify, and validate XML instantly in your browser — catch syntax errors before you ship. Free, no sign-up needed.