ip address subnet mask calculator

IP Address & Subnet Mask Calculator

Enter an IPv4 address and a subnet mask (dotted decimal like 255.255.255.0 or CIDR like /24 or 24), then click Calculate.

Results will appear here.

Why an IP Address Subnet Mask Calculator Matters

Networking becomes much easier when you can quickly determine network boundaries. An IP address subnet mask calculator helps you convert an address and mask into practical answers: network address, broadcast address, first and last host, wildcard mask, and host capacity. Whether you are configuring routers, VLANs, firewalls, cloud networks, or home labs, this is one of the most useful tools in your workflow.

Instead of doing binary math manually every time, this calculator gives fast and accurate subnet details. That means fewer configuration mistakes, better IP planning, and faster troubleshooting when devices cannot communicate as expected.

Core Concepts in Plain English

1) IPv4 Address

An IPv4 address has 32 bits, shown as four decimal octets (for example, 192.168.1.10). Each octet ranges from 0 to 255.

2) Subnet Mask

A subnet mask separates the network portion from the host portion of the IP address. A common mask is 255.255.255.0, which is equivalent to /24.

3) CIDR Prefix

CIDR notation compresses subnet masks into a slash format like /16, /24, or /30. The number after the slash is how many leading bits are set to 1 in the mask.

4) Network and Broadcast Addresses

  • Network address: identifies the subnet itself.
  • Broadcast address: reaches all hosts in the subnet (for traditional IPv4 broadcast domains).
  • Usable host range: typically between network+1 and broadcast-1, with special handling for /31 and /32.

How to Use This Calculator

  • Enter a valid IPv4 address (example: 10.0.5.19).
  • Enter a subnet mask as either dotted decimal (255.255.255.192) or CIDR (/26).
  • Click Calculate.
  • Review the generated network details and binary representation.

Practical Examples

Example A: 192.168.1.34 with /24

The calculator returns network 192.168.1.0, broadcast 192.168.1.255, and usable host range 192.168.1.1 to 192.168.1.254.

Example B: 172.16.10.130 with /26

A /26 splits a /24 into four blocks of 64 addresses each. In this case, the subnet block might be 172.16.10.128/26 with broadcast 172.16.10.191.

Example C: 10.10.10.2 with /30

/30 subnets are common for point-to-point links (traditional style), giving 4 total addresses and 2 usable hosts.

Common Subnetting Mistakes to Avoid

  • Using a non-contiguous subnet mask (invalid in standard IPv4 subnetting).
  • Assigning the network address or broadcast address to end hosts.
  • Forgetting that /31 and /32 behave differently from typical subnets.
  • Assuming every private IP is routable on the public internet.

Quick CIDR Reference

  • /8 → 255.0.0.0
  • /16 → 255.255.0.0
  • /24 → 255.255.255.0
  • /25 → 255.255.255.128
  • /26 → 255.255.255.192
  • /27 → 255.255.255.224
  • /28 → 255.255.255.240
  • /29 → 255.255.255.248
  • /30 → 255.255.255.252

Final Thoughts

Subnetting is one of the foundational networking skills. The more quickly you can calculate ranges and boundaries, the more confidently you can design and secure networks. Use this calculator whenever you need to verify addressing plans, diagnose routing issues, or check host capacity before deployment.

🔗 Related Calculators

🔗 Related Calculators