IP Base Converter
Convert an IPv4 address between its dotted-decimal form and its 32-bit integer, hexadecimal and binary representations.
About this tool
An IPv4 address is really a single 32-bit number; the familiar dotted-decimal form is just one way to write it. Paste an address in any of four shapes — dotted-decimal (192.168.1.1), a plain 32-bit integer (3232235777), hex (0xC0A80101 or a bare 8-digit C0A80101), or binary (32 bits, or four dotted binary octets) — and the tool detects the shape, validates that the value fits in 0–4294967295, and shows all of the representations at once, plus the reverse-DNS name (1.1.168.192.in-addr.arpa). Everything runs in your browser.
When to use it
Questions
How does it tell hex from decimal for a bare number?
By shape. A 0x prefix is always hex; 32 binary digits are binary; an 8-character string that contains a–f is hex; anything that is all decimal digits is read as a decimal integer. So 3232235777 is decimal and C0A80101 is hex, but an all-digit 8-character string is treated as decimal — prefix it with 0x if you meant hex.
What is the in-addr.arpa value for?
It is the name used for reverse DNS: a PTR lookup for 192.168.1.1 queries 1.1.168.192.in-addr.arpa. The octets are reversed because DNS names get more specific right to left.
Does it handle IPv6?
No. This tool is IPv4 only — the value must fit in 32 bits. IPv6 uses 128-bit addresses and a different text format (and ip6.arpa for reverse DNS).