Networking tools

IPv4 Subnet Calculator

Calculate network and broadcast addresses, CIDR prefixes, subnet masks, wildcard masks, usable host ranges, and binary values. Split an IPv4 network into smaller subnets with this free browser-based tool.

Enter network details

Enter an IPv4 address with a CIDR prefix, or enter the address and subnet mask separately. The calculation updates automatically.

Examples: 192.168.1.130/24 or 10.20.30.77/22. An embedded prefix takes priority over the separate field.
Enter a prefix from 0 to 32, such as 24, or a dotted mask, such as 255.255.255.0. This field is used when the address doesn't already include a prefix or mask.

Load an example

All calculations run in your browser. This tool does not send your network addresses to a server or test the network's connectivity.

Subnet results

These values describe the network block containing the entered IPv4 address.

Normalized network CIDR
192.168.1.0/24
Prefix /24 Private IPv4
Total addresses 256
Usable host addresses 254
Network bits 24
Host bits 8
Network address
192.168.1.0
Broadcast address
192.168.1.255
Subnet mask
255.255.255.0
Wildcard mask
0.0.0.255
First usable host
192.168.1.1
Last usable host
192.168.1.254
Entered IP in hexadecimal
0xC0A80182

Binary representation

Entered IP address 11000000.10101000.00000001.10000010
Subnet mask 11111111.11111111.11111111.00000000
Network address 11000000.10101000.00000001.00000000

Address classification

Private IPv4 range

Private addresses are intended for private networks and are not globally reachable by default.

Subnet splitter

Divide the calculated network into smaller, equal-sized CIDR subnets. For example, a /24 can be divided into four /26 blocks.

The new prefix must be equal to or greater than the original prefix. A longer prefix means a smaller subnet.
Number of subnets 4
Addresses per subnet 64

Calculated subnet blocks
# Subnet CIDR Usable range Usable hosts Broadcast
1 192.168.1.0/26 192.168.1.1 – 192.168.1.62 62 192.168.1.63

What is an IPv4 subnet calculator?

A subnet calculator helps determine the boundaries and address capacity of an IPv4 network. It uses an IP address together with a CIDR prefix or subnet mask to derive the network address, broadcast address, wildcard mask, host range and number of addresses.

Understanding CIDR notation

CIDR notation writes an IPv4 address followed by a slash and a prefix length, such as 192.168.1.0/24. IPv4 addresses contain 32 bits. A /24 prefix identifies 24 network bits and leaves 8 host bits. This gives a block containing \(2^8 = 256\) addresses.

The entered address does not need to be the first address in the block. For example, entering 192.168.1.130/24 resolves to the network 192.168.1.0/24.

Important subnet formulas

For conventional subnet prefixes from /0 through /30, the usual IPv4 host count is total addresses minus two, reserving the network and broadcast addresses. The calculator uses separate rules for /31 and /32 because those edge cases do not follow the ordinary minus-two rule.

Why /31 and /32 require special handling

A /31 is commonly used on a point-to-point link. Under RFC 3021, both addresses can be used as endpoints. A /32 represents a single IPv4 address, often used as a host route. Treating either prefix like a regular subnet and subtracting two addresses would produce the wrong usable-host count.

Private and special-purpose IPv4 addresses

This calculator recognizes common categories such as RFC 1918 private addresses, loopback, link-local, shared address space, documentation blocks, benchmarking ranges, multicast and reserved ranges.

Its classification is intentionally a basic reference, not a promise that an address is publicly reachable. For the authoritative list, see the IANA IPv4 Special-Purpose Address Registry.

Frequently asked questions

How many usable hosts does a /24 subnet have?

A standard /24 contains 256 total addresses and normally provides 254 usable host addresses because the network and broadcast addresses are reserved.

What is the difference between a subnet mask and a wildcard mask?

A subnet mask marks network bits with ones and host bits with zeros. A wildcard mask reverses those bits and is used in some networking configurations, including many Cisco access-control list rules.

Can I enter a dotted subnet mask?

Yes. Enter a valid contiguous subnet mask such as 255.255.255.192 in the prefix field, or append it to the IP address separated by a space.

Does the calculator test whether my IP address is online?

No. It performs address arithmetic locally. It does not ping devices, perform DNS lookups, inspect routing tables or test internet connectivity.

Can I export the calculated subnet list?

Yes. The subnet splitter downloads a CSV containing subnet CIDRs, network and broadcast addresses, host ranges and address counts. To prevent accidental enormous exports, the tool caps CSV exports at 4,096 subnet rows.

More technical references

RFC 4632: Classless Inter-domain Routing (CIDR) explains CIDR prefix notation and address blocks.

IANA: Private-use IPv4 addresses lists the private-use ranges.