You may have seen an IPv4 address show up in IPv6 form in a system log or network config, like ::ffff:192.168.1.1. Here's what that notation means.
What an IPv4-mapped IPv6 address is
This is a special format (RFC 4291) for representing an IPv4 address within IPv6 address space in dual-stack environments. The first 80 bits are 0, the next 16 bits are all 1 (ffff), and the last 32 bits hold the IPv4 address directly, producing ::ffff:a.b.c.d.
How the conversion works
Just carry the IPv4 address's four octets straight into the last 32 bits. For example, 192.168.1.1 becomes ::ffff:192.168.1.1. Written purely in hex it would be ::ffff:c0a8:0101, but by convention the last 32 bits are kept in the original dotted-decimal form.
Where you'll run into it
This shows up often when analyzing connection logs on a dual-stack server, handling legacy IPv4 clients on an IPv6-only network, or in socket programming when an AF_INET6 socket is configured to also accept IPv4 connections (which then appear in mapped form).
Something to keep in mind
This mapped address isn't a true "native" IPv6 address โ it's a compatibility notation, not used for actual internet routing. It's mainly for a local system to handle IPv4 and IPv6 sockets through one unified code path.