IP Subnet Calculator
Calculate IPv4 subnet details from an IP address and CIDR prefix or subnet mask. See network address, broadcast, host range, wildcard mask, and binary representations.
Subnet Details
/24 — Class CIP Address192.168.1.0
Subnet Mask255.255.255.0
Wildcard Mask0.0.0.255
Network Address192.168.1.0
Broadcast Address192.168.1.255
First Host192.168.1.1
Last Host192.168.1.254
Total Addresses256
Usable Hosts254
Binary Representation
IP Address
11000000.10101000.00000001.00000000
Subnet Mask
11111111.11111111.11111111.00000000
24 network bits + 8 host bits
Common CIDR Reference
| Prefix | Mask | Usable Hosts |
|---|---|---|
| /8 | 255.0.0.0 | 16,777,214 |
| /16 | 255.255.0.0 | 65,534 |
| /20 | 255.255.240.0 | 4,094 |
| /24 | 255.255.255.0 | 254 |
| /25 | 255.255.255.128 | 126 |
| /26 | 255.255.255.192 | 62 |
| /27 | 255.255.255.224 | 30 |
| /28 | 255.255.255.240 | 14 |
| /29 | 255.255.255.248 | 6 |
| /30 | 255.255.255.252 | 2 |
| /31 | 255.255.255.254 | 2 |
| /32 | 255.255.255.255 | 1 |
How to Use IP Subnet Calculator
- 1Enter an IPv4 address or CIDR notation (e.g., 192.168.1.0/24).
- 2Select or type a subnet mask / prefix length.
- 3View calculated network address, broadcast, and host range.
- 4Copy any value or use presets for common subnets.
Zenovay
Privacy-first analytics for your website
Understand your visitors without invasive tracking. GDPR compliant, lightweight, and powerful.
Related Tools
Password GeneratorGenerate strong, random passwords with customizable length, characters, and complexity.
Password Strength CheckerCheck how strong your password is. Get an estimated crack time and improvement suggestions.
HMAC GeneratorGenerate HMAC signatures using SHA-256, SHA-384, or SHA-512 with the Web Crypto API.
AES Encryption/DecryptionEncrypt and decrypt text using AES-GCM with PBKDF2 key derivation. Runs entirely in your browser.
Frequently Asked Questions
What is CIDR notation?▾
CIDR (Classless Inter-Domain Routing) notation represents an IP address and its routing prefix as a single string: IP/prefix-length. For example, 192.168.1.0/24 means the first 24 bits are the network portion and the remaining 8 bits are the host portion. This replaced the older classful networking (Class A/B/C) and allows more flexible allocation of IP address space. /24 ≈ 256 addresses, /16 ≈ 65,536, /8 ≈ 16.7 million.
What is a subnet mask?▾
A subnet mask is a 32-bit number that separates the network portion from the host portion of an IPv4 address. Written in dotted-decimal, a /24 prefix gives mask 255.255.255.0. Bitwise AND of an IP with its mask gives the network address. The complement (inverted mask) is the wildcard mask — used in ACLs (access control lists) in Cisco IOS and Juniper configurations.
What is the network address vs broadcast address?▾
Network address: first address in the subnet (host bits all zero). It identifies the subnet and cannot be assigned to a host. Broadcast address: last address (host bits all one). Packets sent to this address are delivered to all hosts in the subnet. Usable host addresses are everything between these two. A /30 has 4 addresses: 1 network, 2 hosts, 1 broadcast — commonly used for point-to-point links.
How many hosts can fit in a subnet?▾
Usable hosts = 2^(32 - prefix) − 2. The −2 subtracts the network and broadcast addresses. Common sizes: /24 → 254 hosts, /25 → 126, /26 → 62, /27 → 30, /28 → 14, /29 → 6, /30 → 2. Special cases: /31 (2 addresses, no broadcast — RFC 3021 for point-to-point) and /32 (1 address — host route, used for loopbacks and management).
What is a wildcard mask?▾
A wildcard mask is the bitwise inverse of the subnet mask: 0 bits mean "must match", 1 bits mean "any value". For 255.255.255.0 mask, the wildcard is 0.0.0.255. Wildcard masks are used in: Cisco ACLs (access-control lists), OSPF network statements, and firewall rules. Unlike subnet masks (contiguous 1s), wildcard masks can be non-contiguous for matching specific bit patterns.