Binary to Decimal
Convert binary numbers to decimal instantly.
How to use this tool
- Enter binary in the fields above.
- Results update instantly as you type — or click Calculate.
- Read your decimal and the full breakdown beneath it.
Convert binary numbers to decimal instantly.
Formula
Decimal = each binary digit × 2position, summed from right to left
decimal = parseInt(binary, 2)
For example, binary 1010 = 1×23 + 0×22 + 1×21 + 0×20 = 8 + 0 + 2 + 0 = 10.
How it works
Parse each digit of the binary string from right to left, multiplying each bit (0 or 1) by 2 raised to its zero-indexed position, then sum all the products. The rightmost digit is position 0 (value 1), the next is position 1 (value 2), then 4, 8, 16, and so on — each position doubles in value moving leftward.
Common mistake: Counting bit positions from the left rather than the right (i.e., starting at position 0 on the wrong end) reverses the positional values and produces an incorrect decimal result.
Worked example
Convert binary 1010 to decimal
- Write out the binary digits with positional values: 1×2³, 0×2², 1×2¹, 0×2⁰.
- Calculate each term: 8 + 0 + 2 + 0.
- Sum the results: 8 + 2 = 10.
10 — binary 1010 equals decimal 10.
Common mistakes to avoid
- Reading bit positions from left to right (most significant bit = position 0) instead of right to left, reversing all the exponents.
- Including characters other than 0 and 1 (e.g., spaces or the letter O) in the binary string, causing a parse error or wrong result.
- Forgetting that leading zeros are valid and do not change the value — 0101 = 5, not a separate number.
Key terms
- Binary (base-2)
- A number system using only the digits 0 and 1, where each position represents a power of 2.
- Decimal (base-10)
- The standard number system using digits 0–9, where each position represents a power of 10.
- Bit
- A single binary digit — either 0 or 1; the smallest unit of digital information.
- Positional notation
- A numeral system where the value of a digit depends on its position in the number, not just the digit itself.
Frequently asked questions
- How many decimal digits can an 8-bit binary number represent?
- An 8-bit number ranges from 00000000 (0) to 11111111 (255), covering the decimal range 0-255.
- What is binary 1111 in decimal?
- 1x8 + 1x4 + 1x2 + 1x1 = 15.
- Are binary numbers case-sensitive?
- No — binary digits are only 0 and 1, so there is no case distinction.