Transform any IPv6 address into a 32‑character hexadecimal string (128‑bit raw hex). This tool handles compressed IPv6full IPv6, and IPv4‑mapped addresses like  ::ffff:192.0.2.1.  Perfect for network programmingpacket analysis, and firewall rule generation.

IPv6 to Hexadecimal Converter

🌐 IPv6 → Hexadecimal Converter

Enter an IPv6 address → get 32‑character hex code

🔢 HEXADECIMAL (32 chars / 128-bit)
💡 Expanded IPv6 will appear here

Example conversions (tool in action)

 

loop back ipv6 to hexadecimal

Compressed global unicast

What is IPv6 to Hexadecimal Conversion?

An IPv6 address consists of 128 bits, usually written as 8 groups of 4 hexadecimal digits like (2001:0db8:85a3::8a2e:0370:7334). Converting it to a continuous hexadecimal string removes colons and ensures each group is exactly 4 digits (leading zeros added). The result is a 32‑character hex string that represents the raw binary data.

🔧 Key use cases

  • Low‑level packet crafting (Scapy, raw sockets)
  • Firewall binary matching – some advanced firewalls match on hex patterns
  • DNS over binary protocols – hex encoding for resource records
  • Embedded systems with limited string parsers
  • Network forensics   searching raw packet dumps for IPv6 hex fingerprints

⚙️ How the converter works (step‑by‑step)

  1. Expand compression – replace :: with the appropriate number of zero groups.
  2. Validate each hextet—ensure only hexadecimal digits (a‑f, 0‑9) and correct length (≤4).
  3. Pad with leading zeros – every hextet becomes exactly 4 hex digits.
  4. Concatenate – join all 8 hextets into one continuous 32‑character string.

For IPv4‑mapped IPv6 addresses (e.g., ::ffff:192.0.2.1), the tool ext

Example mapping table

 

IPv6 Address (human readable) 32‑character Hexadecimal (machine ready)
::1 00000000000000000000000000000001
fe80::1 fe800000000000000000000000000001
2001:db8::1 20010db8000000000000000000000001
::ffff:192.0.2.1 00000000000000000000ffffc0000201
2001:0db8:85a3:0000:0000:8a2e:0370:7334 20010db885a3000000008a2e03707334