Binary Calculator

This calculator converts values among binary, decimal, octal, and hexadecimal for programmers, students, and people deciphering machine-friendly numbers.

The interactive binary calculator loads right here. If it hasn't appeared, refresh the page.

Choose the number system of the input, enter the value, then select the output system. Binary uses digits 0 and 1, octal uses 0 through 7, decimal uses 0 through 9, and hexadecimal adds A through F for values 10 through 15.

A positional number equals the sum of each digit × base^position, counting positions from 0 at the right. For example, binary 1011 = 1 × 2³ + 0 × 2² + 1 × 2¹ + 1 × 2⁰.

Worked example

Binary 1011 equals decimal 11. The same value is octal 13 and hexadecimal B.

Common questions

Why does hexadecimal use letters?

A base-16 system needs six digits beyond 0 through 9. A through F represent decimal values 10 through 15.

Do leading zeros change the value?

No. Binary 00101 and 101 both equal decimal 5, though leading zeros may be kept to show a fixed bit width.

Related math tools

More from DoesWhat: free calculators · emoji meanings · quick answers · the DoesWhat blog