Number Converters · Browser · Free

Decimal to Binary Converter

Type a decimal number and read back the same value in binary. A leading minus sign, scientific e-notation, and a fractional point are all accepted, and several numbers typed with spaces between them are converted one at a time.

What this tool does

Decimal is base 10, the counting system used every day. Binary is base 2, so a binary number is written with the digits 0 and 1 only. The converter takes the decimal value you type and writes it out in binary, and it shows the hexadecimal and octal forms beside it. Letters in the answer print in upper case.

You can type values directly or tap the on-screen keypad that appears on focus with digits 0 through 9, a minus sign, and a decimal point. Decimals can also be entered in scientific e-notation, such as 5.72e2 for 572.

The Swap conversion button switches the From and To units and places the current result back into the input field to convert in reverse. Enabling the Padding option aligns positive binary answers to standard byte or word boundaries (8, 16, or 32 bits), while Digit grouping organizes bits into 4-bit clusters. For integer conversions, Little endian and Big endian byte tables break down the byte address and data pairs.

How the positional method works

A binary number is read by place value. Starting at the right, the places are worth 1, 2, 4, 8, 16, 32 and 64, each one double the place before it, and the digit in each place is either 0 or 1.

The table lists 15 as 1111. Each of the four places holds a 1, so the value is the sum of the places worth 8, 4, 2 and 1.

The table lists 10 as 1010. Here only the places worth 8 and 2 hold a 1, and those two places make 10.

The table lists 16 as 10000. A single 1 standing in the place worth 16, with zeros behind it, is exactly that amount.

Decimal to binary formula

To turn a decimal number into binary by hand, work out which places — 64, 32, 16, 8, 4, 2, 1 — are used up by the number, put a 1 in each of those places and a 0 in the rest, and read the digits off from left to right.

To go the other way and check your answer, multiply each digit by the place it stands in and add the results: digit × 8 + digit × 4 + digit × 2 + digit × 1. For the binary number 1010 that is 1 × 8 + 0 × 4 + 1 × 2 + 0 × 1, which the table gives as the decimal number 10.

Decimal to binary conversion table
Decimal (base 10)Binary (base 2)
00
11
210
311
7111
81000
101010
151111
1610000
3111111
32100000
641000000
1001100100
25511111111
256100000000
102410000000000