TECHNOLOGY
IPv4 subnet calculator
Calculate an IPv4 CIDR network, subnet and wildcard masks, broadcast address, usable host range and address counts with explicit /31 and /32 behavior.
Neutral presentation is active.
No regional currency, unit or language profile is applied. This choice does not convert values or change formulas, results, routes or legal guidance.
Network address
192.168.1.0/24256 total · 254 usable addresses- Subnet mask
- 255.255.255.0
- Wildcard mask
- 0.0.0.255
- Broadcast address
- 192.168.1.255
- Usable range
- 192.168.1.1 – 192.168.1.254
- Entered address role
- host
- RFC 1918 private range
- Yes
- Binary subnet mask
- 11111111.11111111.11111111.00000000
Save useful calculators here for a quick return. Nothing is sent to an account or server.
Verification and calculation details
- Purpose
- IPv4 subnet calculator
- Variables and units
- Use the labelled fields and units shown in the calculator. Results use those units unless a conversion is stated.
- Formula and method
- The exact formula and worked example are shown below. Deterministic formula executed locally in the browser.
- Assumptions
- Only entered values and stated assumptions are included. Local fees, rules and professional requirements are excluded unless explicitly shown.
- Engine version
- 1.0.0
- Production verification baseline
- Release 63 · source
998803f - Verification run
release-v63-2026-09-20- Last verified
- — Automated release checks passing
Read the Calculation Standard · Report a calculation or source issue
How this calculator works
Convert the four IPv4 octets to one 32-bit integer. Build the prefix mask from the leading CIDR bits, calculate network = address AND mask, wildcard = NOT mask, and broadcast = network OR wildcard. Usable bounds exclude network and broadcast for /0 through /30; RFC 3021 permits both /31 addresses and /32 represents one host.
Variables and inputs
- IPv4 address
- Required numeric input. exactly four decimal octets; each octet from 0 to 255; no ambiguous leading zeroes.
- CIDR prefix
- Required numeric input. whole number from 0 through 32.
How to interpret the result
The calculator returns network address and prefix, subnet and wildcard masks, broadcast address, first and last usable addresses, total and usable address counts, address role, RFC 1918 private-range status, binary subnet mask. Read each output against the assumptions you entered, compare alternatives one variable at a time, and use the result as an estimate rather than a promise.
Common mistakes to avoid
- Mixing units or entering a rate as a decimal when the field requests a percentage.
- Rounding intermediate values instead of the final displayed result.
- Leaving out a cost, timing rule or local requirement listed in the assumptions below.
Practical uses
Use the ipv4 subnet calculator to check a real scenario, compare a changed assumption and explain the arithmetic before relying on a quote, specification or decision.
Worked example
For 192.168.1.42/24, the mask is 255.255.255.0, the network is 192.168.1.0, the broadcast address is 192.168.1.255 and the ordinary usable range is 192.168.1.1 through 192.168.1.254: 254 usable addresses out of 256 total.
Assumptions and limitations
- input uses conventional decimal dotted notation
- usable address counts follow ordinary subnet rules plus RFC 3021 for /31
- private status tests only the RFC 1918 blocks
- not-private does not prove globally routable because special-purpose and reserved ranges also exist
- network policy, routing, VLANs, DHCP reservations and provider assignments are outside this arithmetic
Important notes
Results are estimates based on the values entered. Confirm rates, prices, units and professional requirements that apply in your location. Review the Answer Atlas Calculation Standard and corrections policy for formula, privacy and correction rules.
Frequently asked questions
What does a /24 prefix mean?
It means the first 24 of 32 IPv4 bits identify the network. The remaining eight bits provide 256 total addresses under that prefix.
Why does a /31 show two usable addresses?
RFC 3021 permits both addresses on an IPv4 point-to-point link, avoiding the older network-and-broadcast reservation for that specific prefix length.
Does not-private mean the address is public?
No. RFC 1918 private space is only one classification. Documentation, loopback, link-local, shared and other special-purpose ranges may also not be globally routable.