Skip to content
snip tools

IPv4 to IPv6 converter

Convert an IPv4 address to its IPv6-mapped, compatible and 6to4 forms.

Runs 100% in your browser

How to convert IPv4 to IPv6

  1. Enter an IPv4 address. Type a dotted-decimal IPv4 like 203.0.113.5.
  2. Read the IPv6 forms. Mapped, compatible, fully expanded and 6to4 prefix are shown.

There is no single "IPv6 version" of an IPv4 address

It is tempting to assume an IPv4 address has one canonical IPv6 equivalent, but it does not. IPv6's address space is so much larger (128 bits versus 32) that an IPv4 address can be embedded in several different ways depending on what the surrounding system is trying to do — exposing a legacy connection to a modern socket API, tunnelling IPv4 over an IPv6-only path, or translating at a gateway. Each mechanism produces a different-looking address from the same input, which is exactly the confusion this tool clears up: enter one IPv4 address and see each encoding side by side so you can paste the one your tooling actually wants.

The encodings, and where you meet them

The IPv4-mapped form ::ffff:a.b.c.d (RFC 4291 §2.5.5.2) is the one you see most: a dual-stack operating system uses it to hand an incoming IPv4 connection to an application written against the IPv6 API, so a server log on a dual-stack box may show client IPv4 addresses in exactly this shape. The older IPv4-compatible form ::a.b.c.d looks similar but was deprecated by the same RFC and should not be used for anything new — it is included here only so you can recognise it in legacy configs. 6to4 (RFC 3056) maps any public IPv4 address to a deterministic 2002::/16-prefixed /48 so a host could tunnel IPv6 over the IPv4 internet; it is largely retired but still appears in old setups.

Reading the hex, and what this isn't

The conversions are mechanical: the four IPv4 octets become the low 32 bits of the IPv6 address, written as two hex groups (203.0.113.5 becomes cb00:7105), with the rest of the address set by the chosen scheme. That is why the mapped and 6to4 forms look related but sit under different prefixes. One thing to keep in mind: this is address notation, not connectivity — embedding an IPv4 address in IPv6 does not make an IPv4-only host reachable over IPv6; that needs a translator such as NAT64. The whole conversion is pure arithmetic in your browser, so nothing you enter is sent anywhere. To see the same address as raw bits or a 32-bit integer, use the IP to binary converter.

Frequently asked questions

How do you convert an IPv4 to IPv6?
IPv4 addresses do not have a single canonical IPv6 form. The common encodings are the IPv4-mapped IPv6 address (::ffff:a.b.c.d) used by dual-stack sockets, the older IPv4-compatible form (::a.b.c.d), and 6to4 tunnels (2002:a.b:c.d::/48).
What is ::ffff:a.b.c.d?
The IPv4-mapped IPv6 address, RFC 4291 §2.5.5.2. Operating systems use it to expose IPv4 connections through an IPv6 API. The low 32 bits are the IPv4 address; the bits above are zeroed.
What is 6to4?
A transition tunnel where any public IPv4 address gets a /48 IPv6 block as 2002:WWXX:YYZZ::/48 (where WWXX:YYZZ is the IPv4 in hex). Largely deprecated, but you may still see it in legacy configs.
Does the page send my IP anywhere?
No. The conversion is pure math in your browser.