LightAtom

IPv6 Subnet Calculator

Enter an IPv6 address and prefix to see the network, first and last address, how many /64 subnets fit, the address type, and the compressed and expanded forms.

Try: , ,

Address (compressed)
2001:db8:abcd:12::1
Address (expanded)
2001:0db8:abcd:0012:0000:0000:0000:0001
Network
2001:db8:abcd::/48
Network (expanded)
2001:0db8:abcd:0000:0000:0000:0000:0000
First address
2001:db8:abcd::
Last address
2001:db8:abcd:ffff:ffff:ffff:ffff:ffff
Addresses
2^80 (1.21 × 10^24)
/64 subnets
65,536
Type
Documentation (2001:db8::/32)

How to use it

  1. Type an IPv6 address with a prefix length, such as 2001:db8:abcd::/48. Without a prefix, /64 is assumed.
  2. Read the network, the range, the number of /64 subnets and the address type.
  3. Choose a size under “Split into” to list the subnets, for example the /56s or /64s inside a /48.

What the result means

  • Compressed is the canonical short form from RFC 5952: lowercase, no leading zeros, and the longest run of zero groups replaced by ::.
  • Expanded writes all eight groups with four digits each, which is easier to compare and sort.
  • Network is the address with every bit after the prefix set to zero.
  • First and last address bound the subnet. IPv6 has no broadcast address, so every address in the range is usable.
  • /64 subnets is how many standard LAN-sized subnets fit. A /64 is the size used on almost every IPv6 LAN, because SLAAC (automatic addressing) needs 64 host bits.
  • Type tells you what kind of address it is: global unicast (2000::/3), unique local (fc00::/7), link-local (fe80::/10), multicast, loopback or documentation (2001:db8::/32).

Frequently asked questions

How many /64 subnets are in a /48?

65,536. A /48 leaves 16 bits between the prefix and /64, and 2^16 = 65,536. ISPs often give businesses a /48 and home users a /56, which holds 256 /64s.

How do I compress an IPv6 address?

Drop leading zeros in each group, then replace the longest run of two or more all-zero groups with ::, once. 2001:0db8:0000:0000:0000:ff00:0042:8329 becomes 2001:db8::ff00:42:8329. Use lowercase letters.

Why is every IPv6 LAN a /64?

Stateless address autoconfiguration (SLAAC) builds a device's address from a 64-bit network prefix plus a 64-bit interface ID. Smaller subnets break SLAAC, so /64 is the standard size for any network with hosts.

Does IPv6 have a broadcast address?

No. IPv6 replaced broadcast with multicast, for example ff02::1 for all nodes on a link. So unlike IPv4, you don't subtract two addresses from each subnet.

What is fe80:: on my Mac?

A link-local address. Every IPv6 interface has one, created automatically, and it only works on the local network segment. You'll see it in ifconfig output as fe80::…%en0, where %en0 names the interface.

LightAtom team

The people who build LightAtom, a network monitor for macOS.