IPv6 Subnetting Basics

IPv6 uses 128-bit addresses, four times the length of IPv4’s 32 bits. The address space is astronomically large: 2¹²⁸ is roughly 3.4 × 10³⁸ addresses. Subnetting in IPv6 works on the same principle as IPv4 (a prefix length divides network from host), but the conventions and scale are completely different.

IPv6 Address Format

An IPv6 address is written as eight groups of four hexadecimal digits, separated by colons:

2001:0db8:85a3:0000:0000:8a2e:0370:7334

Shorthand rules:

  • Leading zeros in each group can be dropped: 0db8 becomes db8
  • One consecutive run of all-zero groups can be replaced with ::, so the address above becomes 2001:db8:85a3::8a2e:370:7334

IPv6 Prefix Lengths

Like CIDR in IPv4, IPv6 uses prefix lengths. The most common ones:

PrefixPurposeAddresses
/128Single host (loopback)1
/127Point-to-point link (RFC 6164)2
/64Standard subnet2⁶⁴ (about 18.4 quintillion)
/48Typical site allocation2⁸⁰ (65,536 /64 subnets)
/32ISP allocation2⁹⁶

The /64 Rule

In IPv6, every subnet is /64 by convention. The lower 64 bits are the Interface ID (host portion), and the upper 64 bits are the network prefix. This isn’t just convention: SLAAC (Stateless Address Autoconfiguration) requires a /64 prefix to generate addresses from MAC addresses.

This means:

  • You never worry about “how many hosts can fit.” Every subnet has 2⁶⁴ addresses.
  • Subnetting happens in the upper 64 bits, between the site prefix and the /64 boundary.

Typical Allocation Hierarchy

/32   ISP receives from RIR (Regional Internet Registry)
 └── /48   ISP assigns to customer site
      └── /64   Customer creates subnets
           └── /128  Individual hosts

With a /48, a customer has 16 bits of subnet space (bits 49 through 64), which gives 65,536 subnets, each with 2⁶⁴ hosts. There’s no need for VLSM in IPv6.

Key Differences from IPv4

AspectIPv4IPv6
Address size32 bits128 bits
NotationDotted decimalColon hex
Typical subnet/24 (254 hosts)/64 (2⁶⁴ hosts)
VLSM needed?Yes, addresses are scarceNo, addresses are abundant
BroadcastYes (last address)No, uses multicast instead
NAT common?YesNo, every device gets a public address
Reserved per subnet2 (network + broadcast)0 (no broadcast in IPv6)

Private IPv6 Addresses

IPv6 has two types of non-public addresses:

  • Link-local (fe80::/10): auto-configured on every interface, not routable beyond the local link.
  • Unique Local (fc00::/7, typically fd00::/8): the IPv6 equivalent of RFC 1918. Use these for internal networks that don’t need internet routing.

Getting Started

If you’re new to IPv6, the key insight is: don’t think about conservation. In IPv4, you carefully calculate how many hosts you need and pick the smallest subnet that fits. In IPv6, every subnet is /64 with effectively unlimited hosts. Your planning focuses on how many subnets you need (determined by the bits between your allocation prefix and /64), not how many hosts per subnet.

IPv6 Calculator: Coming Soon

We’re building an IPv6 subnet calculator. In the meantime, use our IPv4 calculator and VLSM planner for your IPv4 needs.

References