How binary to decimal conversion works
Binary is base 2: every digit is either 0 or 1 and represents a power of two. Reading from the right, the place values are 1, 2, 4, 8, 16, and so on. To convert, multiply each digit by its place value and add the results. For 1010: 1×8 + 0×4 + 1×2 + 0×1 = 10. The calculator uses the same logic to turn any string of 0s and 1s into a base-10 number.
A shortcut worth learning: doubling. Start at the leftmost bit with 0, then for each digit double what you have and add the digit. For 1010 that runs 0, 1, 2, 5, 10 - the same answer with no powers to memorise.
For the same task from a slightly different angle, try the binary to text calculator.
How to use this calculator
Type a binary number (only 0s and 1s) into the box and read the decimal result. Spaces are ignored, so you can paste grouped bytes like 1010 0011. To go the other direction, use the decimal to binary calculator.
Everything runs in your browser, so the number you type is never uploaded or stored. Leading zeros are harmless: 0000 1010 and 1010 both give 10, so grouped bytes from a hex dump paste in cleanly.
If you are checking your work, the decimal to hex calculator gives you a second reference point.
Binary to decimal reference table
Common conversions:
| Binary | Decimal |
|---|---|
| 0001 | 1 |
| 0010 | 2 |
| 0101 | 5 |
| 1010 | 10 |
| 1111 | 15 |
| 11111111 | 255 |
Need hexadecimal instead? Try the hex to decimal calculator.
The values above are the ones worth recognising on sight. 1111 is 15, the largest value in four bits (one hex digit), and 11111111 is 255, the largest in one byte.
Frequently asked questions
- What is 1010 in decimal?
- Binary 1010 equals decimal 10: 1×8 + 0×4 + 1×2 + 0×1 = 10.
- How do I convert binary to decimal by hand?
- Multiply each binary digit by its place value (1, 2, 4, 8, … from the right) and add the products together.
- What is 11111111 in decimal?
- 255. Eight 1s is the largest value a single byte can hold, from 0 to 255.
- Can binary have decimals or negatives?
- This tool converts non-negative whole binary numbers. Fractional binary and signed (two's complement) values use extra rules not covered here.
- How long a binary number can I convert?
- Up to 53 bits the result is exact, which covers any value below about 9 quadrillion. Longer strings still convert but may lose precision at the low end, because browsers store numbers as double-precision floats.