Skip to content
JustTools

IP Subnet Calculator

Type an IP address with a prefix or subnet mask to get the network and broadcast address, usable host range, wildcard mask and binary view — then split it into subnets, plan VLSM or summarise routes.

Runs in your browser Free · no sign-up

At a glance

  • Works out the network address, broadcast address, first and last usable host, total and usable addresses, subnet mask, wildcard mask and binary form of any IPv4 or IPv6 block.
  • Accepts CIDR (192.168.1.10/24), an address with a mask (10.0.0.1 255.255.240.0), a Cisco wildcard mask, or IPv6 in any notation, and writes IPv6 the RFC 5952 way.
  • Names the address type — private (RFC 1918), CGNAT (100.64.0.0/10), loopback, link-local, multicast, documentation, unique local or global unicast — and the classful class.
  • Splits a network into equal subnets by count, hosts or prefix, plans VLSM (largest subnet first) and summarises lists of networks or ranges into the fewest CIDR blocks.
  • Handles the edge cases exams ask about: /31 point-to-point links (RFC 3021), /32 hosts, /0, and IPv6 counts too big for ordinary numbers.
  • Gives the reverse DNS zone (in-addr.arpa / ip6.arpa), checks whether an address is inside the network, and exports subnet tables as CSV. Everything is calculated in your browser.

Step by step

How to calculate a subnet

  1. 1

    Enter an address

    Type an IP with its prefix, such as 192.168.1.10/24, or pick the subnet mask from the list.

  2. 2

    Read the results

    See the network address, broadcast address, usable host range and number of hosts instantly.

  3. 3

    Split or plan

    Switch to Split network to divide it into subnets, or VLSM to size subnets for each LAN.

  4. 4

    Export

    Copy the details or download the subnet table as CSV for your documentation.

Features

Everything you need, nothing you don’t

Every subnet value

Network, broadcast, host range, mask, wildcard, hex, binary and reverse DNS — copy them all in one click.

IPv4 and IPv6

One calculator for both, with BigInt maths so even a /32 IPv6 allocation is counted exactly.

Subnetting made easy

Split a network by the number of subnets or hosts you need, and see every resulting subnet in a table.

VLSM planner

List your LANs and how many devices each has; get the smallest fitting subnet for each, with room to grow shown.

Route summarisation

Merge networks, single addresses and ranges into the fewest CIDR blocks, or find the one supernet that covers them.

Exam-ready

Binary view with network bits highlighted, class and the /31 and /32 rules — handy for CCNA and university networking.

IPv4 subnet mask cheat sheet

PrefixSubnet maskWildcardAddressesUsable hosts
/8255.0.0.00.255.255.25516,777,21616,777,214
/16255.255.0.00.0.255.25565,53665,534
/20255.255.240.00.0.15.2554,0964,094
/21255.255.248.00.0.7.2552,0482,046
/22255.255.252.00.0.3.2551,0241,022
/23255.255.254.00.0.1.255512510
/24255.255.255.00.0.0.255256254
/25255.255.255.1280.0.0.127128126
/26255.255.255.1920.0.0.636462
/27255.255.255.2240.0.0.313230
/28255.255.255.2400.0.0.151614
/29255.255.255.2480.0.0.786
/30255.255.255.2520.0.0.342
/31255.255.255.2540.0.0.122 (point-to-point)
/32255.255.255.2550.0.0.011 (single host)

Private and special IPv4 ranges

RangeUse
10.0.0.0/8Private network (RFC 1918) — large companies and data centres
172.16.0.0/12Private network (RFC 1918) — 172.16.0.0 to 172.31.255.255
192.168.0.0/16Private network (RFC 1918) — home and office routers
100.64.0.0/10Carrier-grade NAT — ISPs, especially mobile data, share public IPs
169.254.0.0/16Link-local — self-assigned when DHCP fails
127.0.0.0/8Loopback — the computer itself (localhost)

How subnetting works

An IPv4 address has 32 bits. The prefix length — the number after the slash — says how many of them identify the network; the rest number the hosts inside it. A /24 leaves 8 host bits, so 2⁸ = 256 addresses. The first is the network address and the last the broadcast address, so 254 are usable for devices.

Every extra prefix bit halves the block: a /24 splits into two /25s, four /26s or eight /27s. VLSM (variable-length subnet masking) uses different sizes inside one network — a /25 for 100 office PCs, a /30 for a router link — to avoid wasting addresses. IPv6 LANs simply use /64 each; sites usually get a /48 or /56.

FAQ

Frequently asked questions

How many usable hosts does a /24 have?

254. A /24 has 256 addresses, but the first (network) and last (broadcast) can’t be given to devices. In general, usable hosts = 2^(32 − prefix) − 2, except /31 and /32.

What is a wildcard mask?

The inverse of the subnet mask: 0 bits must match and 1 bits can be anything. For 255.255.255.0 it is 0.0.0.255. Cisco access lists and OSPF network statements use wildcard masks.

How do I find the network and broadcast address?

The network address is the IP with all host bits set to 0 (a bitwise AND with the mask); the broadcast address has all host bits set to 1. For 192.168.1.10/24 they are 192.168.1.0 and 192.168.1.255.

Can a /31 be used?

Yes, on point-to-point links between two routers. RFC 3021 lets both addresses be used because a link with two ends needs no broadcast address.

What subnet size should I use for an IPv6 LAN?

A /64. Stateless address autoconfiguration (SLAAC) needs it, and a /64 still holds 18 quintillion addresses. Give each site a /48 or /56 to split into /64s.

What is VLSM?

Variable-length subnet masking: dividing one network into subnets of different sizes to match each LAN’s needs. Allocate the largest subnet first so every block stays aligned — the VLSM tab does this for you.

Keep going

Browse every tool

Last updated Report a problem or suggest a feature