IPv6 Address Compressor
Shorten address notation.
IPv6 Address Compressor: inputs and results
Enter an IP address, CIDR prefix, or range. Then check its first and last address below.
Calculated Boundaries & ParametersReady
Key Capabilities
- •100% Client-Side: Zero telemetry or server latency.
- •RFC Compliant: Exact 32-bit and 128-bit integer precision.
- •Quick Copy: Instant access to CIDR, mask, and range bounds.
- •Cross-Platform: Works on desktop, tablet, and mobile browsers.
Related IPv6 ToolsAll Tools
IPv6 Range Calculator
Find IPv6 prefix boundaries.
IPv6 Subnet Calculator
Calculate prefix details and address counts.
IPv6 /127 Link Planner
Divide a parent prefix into address pairs.
IPv6 /128 Address Calculator
Calculate single-address IPv6 prefix details.
IP Address Validator
Check IPv4 or IPv6 address syntax.
IPv6 Binary Converter
Display address bits.
How IPv6 Address Compressor Works?
The IPv6 Address Compressor works by applying the 4 RFC 5952 rules: drop leading zeros, replace the longest run of 2 or more zero groups with ::, pick the first run on a tie, and use lowercase.
Enter an address
Type any form, such as
2001:0DB8:0000:0000:0001:0000:0000:0001.Drop leading zeros
Each group loses its leading zeros:
0DB8→db8.Find the longest zero run
The address has 2 runs of 2 zero groups. The first run wins the tie.
Write the canonical form
The result is
2001:db8::1:0:0:1.
IPv6 Address Compressor Formula
The IPv6 Address Compressor formula is Canonical = lowercase(strip leading zeros) with "::" replacing the longest zero-group run of length ≥ 2.
Leading zeros
0db8 → db8, 0000 → 0Every group keeps at least 1 digit.
Longest run
max(run length), length ≥ 2A single zero group stays as "0".
Tie rule
first run winsRFC 5952 section 4.2.3.
Case rule
a–f in lowercaseRFC 5952 section 4.3.
Worked example: 2001:0DB8:0000:0000:0001:0000:0000:0001
Strip zeros = 2001:db8:0:0:1:0:0:1 Zero runs = groups 3–4 (length 2), groups 6–7 (length 2) Tie → first run Result = 2001:db8::1:0:0:1
IPv6 Address Compressor Conversion Table
The IPv6 Address Compressor conversion table compresses 10 full IPv6 addresses into RFC 5952 canonical form.
| Full Form | Canonical Form | Characters Saved |
|---|---|---|
| 2001:0db8:0000:0000:0001:0000:0000:0001 | 2001:db8::1:0:0:1 | 22 |
| 2001:0db8:0000:0000:0000:0000:0000:0001 | 2001:db8::1 | 28 |
| 2001:0db8:0000:0001:0000:0000:0000:0001 | 2001:db8:0:1::1 | 24 |
| fe80:0000:0000:0000:0202:b3ff:fe1e:8329 | fe80::202:b3ff:fe1e:8329 | 15 |
| 2001:0db8:0001:0000:0001:0001:0001:0001 | 2001:db8:1:0:1:1:1:1 | 19 |
| 0000:0000:0000:0000:0000:0000:0000:0001 | ::1 | 36 |
| ff02:0000:0000:0000:0000:0000:0000:00fb | ff02::fb | 31 |
| 2001:0db8:85a3:0000:0000:8a2e:0370:7334 | 2001:db8:85a3::8a2e:370:7334 | 11 |
| fd00:0000:0000:0000:0000:0000:0000:0000 | fd00:: | 33 |
| 2001:4860:4860:0000:0000:0000:0000:8888 | 2001:4860:4860::8888 | 19 |
What is IPv6 Address Compressor?
The IPv6 Address Compressor is a tool that shortens an IPv6 address to its canonical text form defined by RFC 5952.
RFC 4291 permits many valid spellings of one address. 2001:db8:0:0:1::1, 2001:db8::1:0:0:1, and 2001:DB8:0:0:1:0:0:1 are all legal. RFC 5952, published in 2010, picks exactly 1 recommended form so that logs, configurations, and documentation stay consistent.
A single zero group is never shortened to ::. The address 2001:db8:1:0:1:1:1:1 keeps the 0, since :: must stand for at least 2 groups.
What are the uses of IPv6 Address Compressor?
There are 4 main uses of the IPv6 Address Compressor, including documentation, deduplication, and config consistency.
Writing documentation
Canonical addresses are shorter and match what readers see in device output.
Deduplicating address lists
Different spellings of 1 address collapse into 1 canonical entry.
Keeping configurations consistent
Configuration templates use canonical form so diffs show real changes only.
Matching monitoring output
Most operating systems print canonical form. Compressed inputs match those records.