Menu

Earn Premium with Referrals

Invite your friends and earn Premium rewards through our referral program.

See how it works and start inviting friends.

IPv6 Fundamentals
CN

IPv6 Fundamentals

The future of IP: Understand the 128-bit address space and the features that make IPv6 superior to IPv4.

IPv4 uses 32-bit addresses — about 4.3 billion. IPv6 uses 128-bit addresses — 340 undecillion (3.4×10{38}3.4 \times 10^\{38\}). That’s enough for every grain of sand on Earth to have its own IP.

Address Format

IPv6 is written as 8 groups of 4 hex digits, separated by colons:

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

Shortening rules:

  1. Leading zeros in a group can be omitted → 0370370
  2. One contiguous group of all-zero groups can be replaced with ::
    • 2001:0db8:85a3:0000:0000:8a2e:0370:73342001:db8:85a3::8a2e:370:7334

::1 is the IPv6 loopback (equivalent to 127.0.0.1).

Key Differences from IPv4

FeatureIPv4IPv6
Address size32-bit128-bit
NotationDotted decimal (192.168.1.1)Colon hex (2001:db8::1)
NATRequired (address shortage)Not needed
Security (IPsec)OptionalMandatory
BroadcastYesNo (multicast + anycast)
Header processingComplex (checksum, options)Simple (fixed header, no checksum)
FragmentationRouters can fragmentOnly the sender fragments
Address configDHCP (manual or dynamic)SLAAC (Stateless Address Autoconfiguration)

IPv6 Header

Fixed 40-byte header (simpler than IPv4’s variable-length header):

Version (4) | Traffic Class (8) | Flow Label (20)
Payload Length (16) | Next Header (8) | Hop Limit (8)
Source Address (128)
Destination Address (128)

No checksum (higher layers handle it), no fragmentation fields (handled via Path MTU Discovery).

Transition Mechanisms

MethodHow it works
Dual StackDevices run both IPv4 and IPv6 stacks simultaneously
TunnelingIPv6 packets encapsulated inside IPv4 packets (6to4, Teredo)
TranslationNAT64/PAT — translates between IPv6 and IPv4

Dual stack is the most common: if IPv6 works, use it; otherwise fall back to IPv4.

Q: Main differences between IPv4 and IPv6?

A: IPv6 has 128-bit addresses (vs 32-bit), uses hex colon notation (vs decimal), eliminates NAT, makes IPsec mandatory, removes broadcast (uses multicast instead), has a simpler fixed header with no checksum, and uses SLAAC for autoconfiguration.

Q: Why did IPv6 remove broadcast?

A: Broadcast sends to every device on the network, wasting resources. Multicast sends only to devices subscribed to a specific group. Anycast sends to the nearest device. Both are more efficient.

Q: Is IPv6 widely adopted?

A: Yes. Major ISPs, cloud providers (AWS, GCP, Azure), and large sites (Google, Facebook, YouTube) all support IPv6. Global adoption is ~40-50%. Most systems use Dual Stack to coexist with IPv4.

Q: What is SLAAC?

A: Stateless Address Autoconfiguration. A device generates its own IPv6 address using: (1) the network prefix from router advertisements, (2) its own MAC address (or random identifier). No DHCP server needed.

My Private Notes

Notes are auto-saved locally to this device.