User Rating 0.0
Total Usage 0 times
Accepts continuous, space-separated, dot-separated, or colon-grouped binary. Only 0 and 1 digits with optional separators.
Bits: 0 / 128
Presets:
Is this tool helpful?

Your feedback helps us improve.

About

IPv6 addresses are 128-bit identifiers written as eight colon-separated groups of four hexadecimal digits. Miscounting a single bit during manual conversion flips an entire hex nibble, routing traffic to an unintended host or black-holing it entirely. This tool parses raw binary input - continuous, space-delimited, dot-separated, or colon-grouped - strips formatting characters, validates the length against the 128-bit ceiling, and maps each 16-bit block to its hexadecimal equivalent via parseInt(block, 2). It then applies RFC 5952 compression rules: leading zeros within each group are removed, and the longest run of consecutive all-zero groups collapses into a single :: token. Inputs shorter than 128 bits are right-padded with zeros, matching how partial prefixes behave in real routing tables.

The converter assumes well-formed binary digits only (0 and 1). It does not infer intent from ambiguous separators. If your source material already contains hex characters, use a hex-to-IPv6 formatter instead. Pro tip: when debugging firewall rules or ACLs, always verify the full expanded form before applying compression - two different compressed notations can hide the same address, but two different expanded forms never can.

binary to ipv6 ipv6 converter binary converter network tools ipv6 address binary notation 128-bit address

Formulas

An IPv6 address is a 128-bit unsigned integer. The conversion from binary to colon-hex notation proceeds in three stages: grouping, base conversion, and optional compression.

IPv6 = hex(b1..16) : hex(b17..32) :: hex(b113..128)

Each 16-bit group Gi converts to a 4-digit hexadecimal value:

Gi = 15j=0 bj 2j

where bj {0, 1} is the bit at position j (bit 15 is the MSB within each group). The decimal result is then expressed in base 16.

RFC 5952 compression rules: (1) remove leading zeros from each group (00a1 a1); (2) replace the longest contiguous sequence of all-zero groups with ::; (3) if two sequences of equal length exist, replace only the leftmost.

Where b = raw binary string, Gi = the i-th 16-bit group (i [1, 8]), hex = base-16 conversion function, and j = bit index within each group.

Reference Data

IPv6 Address TypePrefix (Binary, first 16 bits)Full IPv6 (Expanded)Compressed IPv6RFC
Unspecified0000...0000 (128 zeros)0000:0000:0000:0000:0000:0000:0000:0000::RFC 4291
Loopback0000...0001 (127 zeros + 1)0000:0000:0000:0000:0000:0000:0000:0001::1RFC 4291
Link-Local Unicast1111111010fe80:0000:0000:0000:...fe80::...RFC 4291
Multicast11111111ff00:0000:...ff00::...RFC 4291
Global Unicast0012000:0000:... to 3fff:ffff:...VariesRFC 3587
Unique Local (ULA)1111110fc00:0000:... to fdff:ffff:...fc00::/7RFC 4193
6to400100000000000102002:xxxx:...2002::...RFC 3056
Teredo0010000000000001 00000000000000002001:0000:...2001:0:...RFC 4380
Documentation0010000000000001 00001101101110002001:0db8:...2001:db8::RFC 3849
All Nodes (Link-Local)Fixed addressff02:0000:0000:0000:0000:0000:0000:0001ff02::1RFC 4291
All Routers (Link-Local)Fixed addressff02:0000:0000:0000:0000:0000:0000:0002ff02::2RFC 4291
Solicited-Node Multicast1111111100000010 ... 1ff02:0000:0000:0000:0000:0001:ffxx:xxxxff02::1:ffxx:xxxxRFC 4291
IPv4-Mapped IPv60000...0000 11111111111111110000:0000:0000:0000:0000:ffff:xxxx:xxxx::ffff:x.x.x.xRFC 4291
Discard-Only00000001000000000100:0000:...100::/64RFC 6666

Frequently Asked Questions

The converter right-pads the input with zeros to reach 128 bits. This matches how network prefix notation works: a /64 prefix means the remaining 64 bits are host bits, defaulting to zero. If you intend a specific host portion, supply all 128 bits explicitly.
RFC 5952 mandates that when two equal-length runs of all-zero groups exist, only the leftmost is collapsed to ::. Some older tools collapse the rightmost instead. This converter follows RFC 5952 strictly. Additionally, leading zeros are always stripped (00ff becomes ff), and hex letters are lowercased per the same RFC.
Yes. The parser strips all spaces, dots, colons, and hyphens before validation. You can paste binary in any common format: continuous (1111111010...), space-delimited (11111110 10000000...), dot-separated (1111.1110.1000...), or colon-grouped (1111111010000000:...). Only characters 0 and 1 (plus separators) are accepted.
An all-zeros 128-bit string yields the unspecified address :: (compressed) or 0000:0000:0000:0000:0000:0000:0000:0000 (expanded). An all-ones string produces ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff, which has no compressible zero groups and therefore the compressed form is identical to the expanded form with leading-zero removal applied.
Exactly 128 binary digits (after stripping separators). Any input exceeding 128 bits is rejected because an IPv6 address is defined as a 128-bit integer. No truncation is performed - this prevents silent data loss that could route packets to a wrong destination.
No. The converter performs a mathematical base-2 to base-16 transformation and applies RFC 5952 formatting. It does not check whether the resulting address falls within a globally routable prefix, a reserved range, or a deprecated block. Consult the IANA IPv6 Special-Purpose Address Registry for routability status.