IP Address Converter
Convert an IPv4 address between dotted, 32-bit integer, hex and binary forms, see its IPv4-mapped IPv6 and reverse DNS names, and whether it is private.
Free · No sign-up · Your inputs stay in your browser
Input
Convert an IPv4 address between formats
Output
192.168.1.1
| Dotted | 192.168.1.1 |
|---|---|
| Integer | 3232235777 |
| Hex | 0xC0A80101 |
| Binary | 11000000.10101000.00000001.00000001 |
| IPv4-mapped IPv6 | ::ffff:192.168.1.1 |
| Reverse DNS | 1.1.168.192.in-addr.arpa |
| Type | Private (RFC 1918) |
MySQL's INET_ATON() and INET_NTOA() convert between the dotted form and an unsigned integer, and an INT UNSIGNED column holds one in 4 bytes instead of up to 15 as text. For mixed v4 and v6, INET6_ATON() into VARBINARY(16), or PostgreSQL's inet type.
Runs in this browser. Nothing you paste is sent to a server.
About this tool
Method, assumptions, practical next steps, and limits.
Storing IPs as integers
An IPv4 address is a 32-bit number, so it fits in an INT UNSIGNED column in four bytes. MySQL's INET_ATON() and INET_NTOA() convert, and range checks become integer comparisons that use an index. For mixed IPv4 and IPv6, MySQL's INET6_ATON() into VARBINARY(16) or PostgreSQL's inet type handle both.
Private and special ranges
10.0.0.0/8, 172.16.0.0/12 and 192.168.0.0/16 are private (RFC 1918), 100.64.0.0/10 is carrier-grade NAT, and 192.0.2.0/24, 198.51.100.0/24 and 203.0.113.0/24 are reserved for documentation, which is why examples use them.