Number systems · Base 2 to base 10

Binary to Decimal Converter

Convert a binary number (base 2) into its decimal (base 10) equivalent. Get an instant result, validate your input, and follow the calculation one bit at a time.

Convert binary to decimal

Use only 0 and 1. Spaces, line breaks, underscores, and an optional 0b prefix are accepted. Maximum length: 512 bits.

Try a binary number

Choose an example to fill the calculator, then select “Convert to decimal.”

Binary 0
Binary 1
Binary 1011
Binary 11001010
Binary 11111111
Binary 100000000

How to convert binary to decimal

Binary uses place values that are powers of two. To convert a whole binary number to decimal, you can multiply each bit by its corresponding power of two and add the products. For long numbers, the doubling method gives the same result without having to write every power explicitly.

Positional-value formula: decimal = bn−1 × 2n−1 + … + b2 × 22 + b1 × 21 + b0 × 20, where every bit b is either 0 or 1 and position 0 is the rightmost digit.

Worked example: 1101₂

BitPositionPlace valueContribution
1323 = 81 × 8 = 8
1222 = 41 × 4 = 4
0121 = 20 × 2 = 0
1020 = 11 × 1 = 1
Sum of contributions8 + 4 + 0 + 1 = 13

Continue working with binary numbers using these related Binarios.org tools.

Frequently asked questions

How do I convert binary to decimal?

Read the binary digits from left to right. Start with a total of zero, double the total for each digit, and add the digit (0 or 1). The final total is the decimal value.

What is 1011 in decimal?

1011₂ equals 11₁₀ because (1 × 2³) + (0 × 2²) + (1 × 2¹) + (1 × 2⁰) = 8 + 0 + 2 + 1 = 11.

Can I convert a long binary number?

Yes. This converter accepts up to 512 binary digits and uses decimal-string arithmetic, so the result is not limited to the usual PHP integer range.

Does this tool accept spaces or a 0b prefix?

Yes. Spaces, line breaks, underscores, and an optional leading 0b prefix are removed before validation. All remaining characters must be 0 or 1.

Does this converter handle signed two’s-complement values?

This tool treats the input as an unsigned binary integer. For signed two’s-complement interpretation, the bit width must be known and the sign bit must be interpreted accordingly.