IP Address Converter – IPv4 to Decimal
Convert an IPv4 address to a decimal number, hexadecimal, binary, octal or IPv4-mapped IPv6 — or paste any of those to get the dotted address back. The format is detected automatically and every result can be copied with one click.
How to use the IP Address Converter – IPv4 to Decimal
- Type an IP address like 192.168.1.1, a decimal number like 3232235777, a hex value (0x…) or binary.
- Every format is shown at once — press ⧉ to copy the one you need.
- Check the address class, type (private or public) and reverse DNS name shown under the results.
How to convert an IPv4 address to a decimal number
- An IPv4 address is four numbers from 0 to 255, called octets. Each octet is one byte, so the whole address is a single 32-bit number. To turn it into that number, multiply each octet by its place value and add them up: first × 16,777,216 + second × 65,536 + third × 256 + fourth.
- Worked example, 192.168.1.1: 192 × 16,777,216 = 3,221,225,472. 168 × 65,536 = 11,010,048. 1 × 256 = 256. Plus the last octet, 1. The total is 3,232,235,777.
How to convert a decimal number back to an IP address
- Divide the number by 16,777,216: the whole part is the first octet. Divide the remainder by 65,536 for the second octet, divide the new remainder by 256 for the third, and what is left is the fourth.
- Worked example, 3232235777: 3232235777 ÷ 16,777,216 = 192, remainder 11,010,305. 11,010,305 ÷ 65,536 = 168, remainder 257. 257 ÷ 256 = 1, remainder 1. The address is 192.168.1.1.
Common IP addresses as numbers
- 192.168.1.1 = 3232235777 = 0xC0A80101 (a common home router address).
- 10.0.0.1 = 167772161 = 0x0A000001 (private network).
- 172.16.0.1 = 2886729729 = 0xAC100001 (private network).
- 127.0.0.1 = 2130706433 = 0x7F000001 (localhost, your own computer).
- 8.8.8.8 = 134744072 = 0x08080808 (a public DNS server).
- 255.255.255.255 = 4294967295 = 0xFFFFFFFF (the largest possible IPv4 value).
Where each format is used
- Decimal: databases and analytics tools often store IPs as one unsigned 32-bit integer, because numbers are smaller to store and quick to sort and compare in ranges, for example in IP geolocation tables.
- Hexadecimal: appears in packet captures, firewall and router logs, and low-level code.
- Binary: makes subnet masks easy to understand, because you can see exactly which bits belong to the network and which to the host.
- IPv4-mapped IPv6: written as ::ffff: followed by the IPv4 address, used by systems that run IPv4 and IPv6 side by side.
Frequently asked questions
How do I convert an IP address to a decimal number?
Multiply the octets by their place values and add them: a × 16,777,216 + b × 65,536 + c × 256 + d. For example 192.168.1.1 = 3,232,235,777.
How do I convert a decimal number back to an IP address?
Paste the number into the converter and the dotted address appears. By hand, divide by 16,777,216, then 65,536, then 256, and use the whole parts as the octets.
What is the largest IPv4 address as a number?
255.255.255.255, which is 4,294,967,295. That is 2 to the power of 32 minus 1, the largest value a 32-bit number can hold.
Why do databases store IP addresses as integers?
A single number takes less space than text and makes it fast to sort addresses and check whether an IP falls inside a range, which is how IP location lookups work.
What is an IPv4-mapped IPv6 address?
::ffff: followed by the IPv4 address, used by dual-stack systems that handle IPv4 and IPv6 together.
What is the reverse DNS name?
The octets in reverse order plus .in-addr.arpa, for example 1.1.168.192.in-addr.arpa. It is used for PTR lookups.
Is anything sent to a server?
No. All calculations run in your browser on your own device.