Skip to content

Binary to Decimal Converter (and Decimal to Binary), With Steps

Convert binary to decimal or decimal to binary, with the powers of 2 or the division by 2 shown, plus hex.

Inputs

Decimal
10

Use this calculator on your own site

Free embed

  • Two lines of HTML, unlimited views
  • Shows a small CalculateEveryday bar, with a credit link under the calculator

What each Binary to Decimal input means

Convert
Binary → decimal reads a string of 0s and 1s; decimal → binary takes an ordinary whole number. Both directions also give the hexadecimal form and the number of bits.
Binary number
Up to 53 binary digits, 0 and 1 only. Spaces are ignored, so a byte can be pasted as 1100 1000. Leading zeros are allowed and change nothing.
Decimal number
A whole number from 0 up to about 9 quadrillion (2⁵³ − 1), the largest a browser holds exactly. No commas, decimal points or minus signs.

Binary to Decimal conversion formula

binary → decimal: Σ digit × 2^position · decimal → binary: divide by 2 repeatedly, read the remainders from the last to the first

N=∑idi 2iN = \sum_{i} d_i \, 2^i

Binary is base 2: each place is worth twice the one to its right — 1, 2, 4, 8, 16 and so on. To turn binary into decimal, add the place values where there is a 1: 1011 is 8 + 2 + 1 = 11. To go the other way, OpenStax Contemporary Mathematics divides by 2 over and over, writing down each remainder, until the quotient is 0; the remainders read from the last to the first are the binary digits. The page shows both methods step by step and gives the hexadecimal form, which groups binary digits in fours.

Binary to Decimal conversion worked example

1010 in binary is 1 × 8 + 0 × 4 + 1 × 2 + 0 × 1 = 10. Going the other way, OpenStax converts 100 by dividing by 2 seven times — remainders 0, 0, 1, 0, 0, 1, 1 — and reads them backwards: 1100100.

More Binary to Decimal examples

2026 to binary: halve it and keep each remainder — 1,013 r 0, 506 r 1, 253 r 0, 126 r 1, 63 r 0, 31 r 1, 15 r 1, 7 r 1, 3 r 1, 1 r 1, 0 r 1. Reading from the last remainder back to the first gives 11111101010, eleven bits. Check: 1024 + 512 + 256 + 128 + 64 + 32 + 8 + 2 = 2026. In hexadecimal it is 7EA.

A byte pasted with a space, 1100 1000. The 1s sit in the 128, 64 and 8 places, so the value is 128 + 64 + 8 = 200. Split into four-bit groups, 1100 is C and 1000 is 8, which is why 200 is C8 in hexadecimal.

Where the Binary to Decimal converter can give the wrong answer

  • Binary digits are 0 and 1 only; spaces between groups are ignored, so 1111 0000 is read as 11110000.
  • Whole numbers only. Fractions such as 0.1 have endless binary expansions.
  • Numbers above 2⁵³ − 1 (about 9 × 10¹⁵) cannot be represented exactly and are rejected.
  • Leading zeros don't change the value: 00101 is 5.

Spotted a mistake? Tell us

Binary to Decimal conversion reference table

Powers of 2: what each binary place is worth
Place (from the right, starting at 0)PowerValueLargest number that fits in the places up to here
02⁰11 (1 bit)
12¹23 (2 bits)
22²47
32³815 (4 bits, one hex digit)
42⁴1631
52⁵3263
62⁶64127
72⁷128255 (8 bits, one byte)
82⁸256511
92⁹5121,023
102¹⁰1,0242,047
152¹⁵32,76865,535 (16 bits)
312³¹2,147,483,6484,294,967,295 (32 bits)
Source: Arithmetic: place values are powers of 2 (OpenStax Contemporary Mathematics, §4.3), and n bits hold 0 to 2ⁿ − 1

Binary to Decimal conversion FAQ

Write the powers of 2 under the digits from the right — 1, 2, 4, 8 … — and add those under a 1. 1101 = 8 + 4 + 1 = 13.