1. Home
  2. Developer tools
  3. Binary to IP

Binary to IP

Turn the bits of an address back into the form you type into a router. Paste a 32-digit binary number, with or without dots between the bytes.

Free, no sign-up. Runs in your browser: nothing is uploaded.

How to use Binary to IP

  1. Paste binary values, one per line.
  2. Read the dotted address for each.
  3. Fix any line that is not exactly 32 bits.

Features

  • Dots and spaces between bytes are optional
  • Checks for exactly 32 digits
  • Works on lists
  • Shows hex, decimal and octal forms
  • Counts the digits in an error message
  • Copy or download

Supported formats

Input

  • Binary strings
  • Typed or pasted text

You get

  • Dotted IPv4 address
  • Octet table

Private by design

Everything you enter is processed by your browser on this device. Nothing is sent to openWorkstand or anyone else, so the Binary to IP is safe for private and work data. After you have used it once while online, it also works without an internet connection. How local processing works

Good to know

  • It expects exactly 32 bits, with or without dots or spaces.
  • Shorter strings are rejected, not padded.

Guide

Rebuilding an IPv4 address from 32 bits

Protocol diagrams, exam questions and low-level debugging output often give an address as raw bits. The page turns a 32-digit binary string into the dotted decimal address people use, and lists the other notations so you can check the result against whatever source you are working from.

The conversion

The 32 digits are split into four groups of eight. Each group is a binary number between 0 and 255: add the place values of the digits that are 1 (128, 64, 32, 16, 8, 4, 2, 1). 11000000 is 128 + 64, so 192. 10101000 is 128 + 32 + 8, so 168. 00000001 is 1. The four numbers joined by dots are the address. The method is the reverse of what the IP to Binary Converter does, and both use the same four-byte reading, most significant byte first.

Accepted input

Type or paste one value per line. Dots and spaces between bytes are optional, so 11000000.10101000.00000001.00000001, 11000000 10101000 00000001 00000001 and the unbroken string all work. The total number of binary digits must be exactly 32. A line with a digit other than 0 or 1, or with 31 or 33 digits, produces a message that quotes the line and says how many binary digits it found. The page does not pad short input, because a missing digit in a pasted value would otherwise silently become a different address.

Reading masks and fields

Because the network part of a subnet mask is a run of ones, converting a mask from bits is a quick way to find its prefix length. 11111111111111111111111111000000 has 26 leading ones, so its dotted form is 255.255.255.192 and it is a /26. The same page helps when a protocol specification draws an address field as a row of bits, or when a lab asks for the address that a given bit pattern represents. For a pattern that includes a host part, convert it here and then use the Subnet Calculator to place it in its network.

A worked example

The sample contains two lines. The first, 11000000.10101000.00000001.00000001, is the address 192.168.1.1: its four groups are 192, 168, 1 and 1, and the page also gives the integer 3232235777, hexadecimal 0xC0A80101 and the label private use (RFC 1918). The second, 00001010000000000000000000000001, has no dots; the first eight digits 00001010 are 10, the next two bytes are zero and the last is 1, so the address is 10.0.0.1.

Limits

The page accepts IPv4-sized input only; a 128-bit string is an IPv6 address and has a separate notation. It converts the bits you give it and says nothing about whether the address is in use or who owns it. When a result looks wrong, check the digit count first: a copied value that lost a leading zero is the most common cause.

Checking your answer

The quickest check is to convert the result back with the IP to Binary Converter and compare. Three slips cause most wrong answers: reading the place values from the left instead of the right (they double as 1, 2, 4, 8, 16, 32, 64, 128 from the right-hand digit), dropping the leading zeros of a byte so that every later byte shifts, and counting digits wrongly so that 31 or 33 digits slip into a 32-bit field. Grouping the digits in eights before you convert, as the page allows with dots or spaces, avoids all three.

Checked against the current version of the Binary to IP on .

Frequently asked questions

Why is my 31-digit binary string rejected?

Padding on the left would be a guess about what you meant. The page requires all 32 digits so that a dropped digit in a copied value is reported instead of changing the address.

Can I paste a subnet mask in bits?

Yes. 11111111111111111111111100000000 converts to 255.255.255.0, a /24 mask. The page shows the dotted result; count the leading ones to find the prefix length.

What address is 11000000.10101000.00000001.00000001?

192.168.1.1. The four bytes are 192, 168, 1 and 1.

Why do I get an error for 8 bits?

An IPv4 address has 32 bits. To convert a single byte use the binary to decimal converter.

Keep working with the result

openWorkstand also includes a free workspace with documents, spreadsheets, tasks, projects and a calendar that save to a folder on your computer.