IPv4 Decimal Converter – Dotted Decimal to Integer | NetworkUstad

Underneath the familiar dotted form, every IPv4 address is a single 32-bit number: 192.168.0.1 is 3232235521. Databases, firewall tables, and geolocation data often store addresses in that integer form because numbers sort, index, and compare faster than strings, while humans read the dotted form. Converting between the two by hand means multiplying octets by powers of 256, which is exactly the kind of arithmetic that invites a slip. This converter does both directions instantly and shows the binary breakdown too, so you can see how the four octets pack into 32 bits.

Quick Answer: Enter a dotted address and click To Decimal, or enter an integer and click To Dotted.

Free Online Tool

IPv4 Decimal Converter

Convert between dotted-decimal IPv4 and its 32-bit decimal integer form.

How to Use the IPv4 Decimal Converter

  1. For dotted to decimal, type the address such as 192.168.0.1.
  2. Click To Decimal and read the 32-bit integer.
  3. For the reverse, type the integer such as 3232235521.
  4. Click To Dotted and read the dotted address.
  5. Check the binary breakdown shown to confirm the packing.
  6. Copy the converted value into your database or rule.

Key Features

  • Both directions: dotted to decimal and decimal to dotted.
  • Validates octet ranges and the 0 to 4294967295 integer range.
  • Shows the 32-bit binary form for verification.
  • Handles 0.0.0.0 and 255.255.255.255 correctly.
  • Rejects negative numbers and decimals with fractions.
  • Runs entirely in the browser with no data sent anywhere.

What the Result Means

The decimal value is the address itself, not a hash or an encoding: converting back must return the original dotted address exactly, and if it does not, one of the two values was mistyped. Small decimals correspond to low addresses in the 0.x.x.x range, which are mostly reserved, while large decimals near 4294967295 sit in the 255.x.x.x range. The binary breakdown is the clearest check: each octet is exactly eight bits, in order, with no gaps.

Worked Example

A database stores blocked addresses as integers, and one entry reads 2886729729. Converting it gives 172.16.5.65, which is immediately recognisable as a private address, and the block entry turns out to be a mistake: a private address should never appear in an external blocklist. Converting the other way, 8.8.8.8 becomes 134744072, which sorts neatly between neighbouring addresses in the same table. In both directions the conversion is exact and reversible, so nothing is lost. The binary breakdown shown by the tool makes the packing visible: the first octet occupies the highest eight bits and the last octet the lowest eight, which is why the decimal grows quickly when the first octet changes and only slowly when the last one does.

Best Practices and Tips

  • Use the integer form when storing addresses in a database for fast range queries.
  • Convert both ends of a range before comparing them numerically.
  • Watch for signed 32-bit systems: addresses above 2147483647 appear negative there.
  • Keep the dotted form in anything a human reads; reserve integers for machines.
  • Verify a conversion by converting back and comparing with the original.

Common Mistakes to Avoid

  • Forgetting that octets are base 256, not base 100 or base 1000.
  • Using a signed integer type that turns high addresses negative.
  • Adding the octets instead of weighting them by position.
  • Assuming the decimal form hides the address: it is trivially reversible.

Frequently Asked Questions

What is 3232235521?

It is 192.168.0.1 as a 32-bit integer: 192 times 256 cubed, plus 168 times 256 squared, plus 0 times 256, plus 1.

What is the largest IPv4 decimal?

4294967295, which is 255.255.255.255, the limited broadcast address.

Is the decimal form the same address?

Yes, exactly. It is the same 32 bits written as one number instead of four octets.

Why do databases store IPs as integers?

Because integer comparison and indexing are faster, and range checks become simple number comparisons.

Related Tools