URL & Network Tools

Network Address Calculator

Enter an IP address and its subnet mask or prefix length to get the network address, also called the network ID or subnet ID. For IPv4 the calculation is shown in binary: the address, the mask, and the result of combining them with a bitwise AND, so you can see which bits belong to the network.

  • Runs in your browser
  • No sign-up
  • Free to use

How to use Network Address Calculator

  1. Enter the IP address.
  2. Enter the mask as /prefix or dotted decimal.
  3. Read the network address.
  4. Follow the binary working to understand it.

Network Address Calculator features

Network address

The first address of the subnet.

Binary working

Address AND mask, bit by bit, for IPv4.

Any notation

Prefix length or dotted mask.

IPv6 too

Network prefix of IPv6 addresses.

Context

Broadcast, host range and subnet size alongside.

Private

Runs in your browser.

When to use Network Address Calculator

  • Finding which subnet a device belongs to.
  • Writing routes and firewall rules.
  • Checking two addresses are on the same network.
  • Learning or teaching subnetting.

Network Address Calculator FAQ

What is a network address?

The first address of a subnet, with all host bits set to zero. It identifies the network itself and is not assigned to a device in IPv4.

How is it calculated?

By a bitwise AND of the address and the subnet mask: each result bit is 1 only where both inputs are 1, which clears all host bits.

Are two addresses on the same network?

They are if they give the same network address with the same mask.

Is the network address usable?

Not for hosts in normal IPv4 subnets. In /31 point-to-point links both addresses are usable.

What about IPv6?

The same AND applies to the 128-bit address and prefix; the result is the network prefix, such as 2001:db8:abcd::/48.

Is anything sent?

No.

The AND that defines a subnet

Every IP address belongs to a network, and the subnet mask says which part of the address names that network. Applying the mask is a single bitwise AND: where the mask has a one, the address bit is kept; where it has a zero, the bit is cleared. The result is the network address.

Seeing the operation in binary removes the mystery. A /20 mask keeps the first twenty bits, which ends partway through the third octet, so the network address changes the third octet in a way that is hard to predict in decimal but obvious in binary. The tool aligns the three binary rows so the boundary is clear.

Network addresses are what routers, firewalls and route tables work with. Two hosts communicate directly only if they share a network address; otherwise traffic goes through a router. Comparing network addresses is therefore the quickest way to diagnose why two devices cannot reach each other.

The same idea extends to IPv6, with 128-bit addresses and prefixes usually of /48, /56 or /64. The binary rows are omitted there for length, but the network prefix and range are calculated the same way.

Other useful tools