IP address converter

Convert an IPv4 address to and from decimal, hex, octal and binary, or expand and compress an IPv6 address, in either direction.

IP address converter

Loading the ip address converter. It runs in your browser.

Why addresses have many forms

An IPv4 address is a 32-bit number; dotted decimal just writes its four bytes. Databases often store it as an integer (192.0.2.1 is 3221225985), packet captures show hex, and subnet maths is easiest in binary.

Some software reads 010.0.0.1 as octal (8.0.0.1). Leading zeros have caused real security bugs, so the converter rejects them in dotted input.

IPv6 forms

The compressed form (RFC 5952) drops leading zeros and replaces the longest run of zero groups with ::. The expanded form shows all 32 hex digits, which is what the reverse DNS name is built from.

Questions

What is an IPv4-mapped IPv6 address?
::ffff:192.0.2.1 is how an IPv6 program represents an IPv4 address internally. You see it in server logs on dual-stack systems.

References