Data & AnalyticsLive🔒 Private

IPv6 Compress Expand

Compress or expand IPv6 addresses to full and abbreviated forms. Free online IPv6 tool. No signup, 100% private, browser-based.

IPv6 Compress Expand

Compressed

2001:db8::ff00:42:8329

How it works

IPv6 addresses are 128-bit numbers formatted as 8 groups of 4 hexadecimal digits separated by colons (2001:0db8:0000:0000:0000:8a2e:0370:7334). Two compression rules reduce verbose addresses: leading zeros in each group may be omitted, and one run of consecutive all-zero groups may be replaced with ::. This tool converts between full and compressed forms.

**Compression rules (RFC 5952)** Leading zero suppression: 0db8 → db8, 0000 → 0. :: substitution: the longest run of consecutive all-zero groups is replaced with :: (ties broken by choosing the leftmost). Only one :: is permitted per address — using it twice is ambiguous. Example: 2001:0db8:0000:0000:0000:8a2e:0370:7334 → 2001:db8::8a2e:370:7334.

**Special addresses** ::1 (loopback, equivalent to IPv4 127.0.0.1). :: (unspecified address). fe80::/10 (link-local addresses, non-routable). fc00::/7 (unique local addresses, RFC 4193 — private address space). 2001:db8::/32 (documentation range, not routable — like 192.0.2.0/24 in IPv4). ::ffff:0:0/96 (IPv4-mapped IPv6 addresses — e.g., ::ffff:192.168.1.1).

**Canonical form** RFC 5952 defines a canonical text representation: use :: for the longest zero run, prefer lowercase hex, never use :: for a single zero group (use :0: instead). Canonical form is important for string-based equality checks — two representations of the same address compare as different strings without normalization.

Frequently Asked Questions

How do I expand a compressed IPv6 address like 2001:db8::1?
Step 1: Expand :: by counting existing groups and replacing :: with the required number of :0000: groups. 2001:db8::1 has 3 groups (2001, db8, 1); 8 groups total needed → :: replaces 5 groups of zeros: 2001:db8:0000:0000:0000:0000:0000:0001. Step 2: Pad each group to 4 digits. Final: 2001:0db8:0000:0000:0000:0000:0000:0001. The :: can only appear once — if you see :: twice in an address, it is malformed.
What is a link-local IPv6 address?
Link-local addresses (fe80::/10) are automatically configured on every IPv6-enabled interface and are only valid on the local network segment — they are not routed. Every interface has a link-local address derived from its MAC address (EUI-64) or randomly generated (privacy extensions). They are used for neighbor discovery (IPv6's replacement for ARP), router discovery, and stateless address autoconfiguration (SLAAC). Link-local addresses appear as fe80::xxxx:xxxx:xxxx:xxxx%interface (the %eth0 suffix identifies the interface).
Is there a private address range in IPv6 like 192.168.x.x in IPv4?
Yes. Unique Local Addresses (ULA, fc00::/7, most commonly fd00::/8) are the IPv6 equivalent of RFC 1918 private addresses (10.x.x.x, 172.16-31.x.x, 192.168.x.x). They are not globally routable and are used for internal network addressing. Unlike IPv4 private ranges (which are shared), ULA addresses include a randomly generated 40-bit prefix (within fd00::/8) that makes them globally unique to your organization, allowing merging networks without address conflicts. Many home routers and enterprise networks use fd::/8 ULA addresses for local subnets.
How do I check if an IPv6 address is valid?
A valid IPv6 address has exactly 8 groups of 4 hex digits separated by colons, OR uses :: to compress one run of consecutive zero groups. Validation rules: exactly one :: (or none). Each group 0–FFFF (0000–FFFF). No leading/trailing colon (except as part of ::). Total expanded length = 128 bits = 8 groups × 16 bits. Invalid: 2001::db8::1 (two :: — ambiguous). Invalid: 2001:0db8:gg00:: (invalid hex 'gg'). Python: ipaddress.ip_address('2001:db8::1') raises ValueError for invalid addresses.