Skip to the converter

HomeNumbers & text

Number bases converter

Binary, octal, decimal and hexadecimal.

Runs in your browserNo sign-upNo watermark

Quick answer

To convert a number between bases, type it in any box: binary, octal, decimal or hex. The others update at once.

Works for very large numbers too: it uses exact whole-number maths, not floating point.

How to use the number bases tool

  1. Click any of the four boxes and type your number.
  2. The other boxes update straight away.
  3. Press Copy next to the one you need.

Computers count in binary (0 and 1). Programmers write the same numbers in hexadecimal (0 to 9 and A to F) because it is shorter. Decimal is the everyday system.

Common questions

How do I convert binary to decimal?

Type the binary number in the Binary box. The decimal value appears in the Decimal box. For example 1010 in binary is 10 in decimal.

How do I convert hex to decimal?

Type the hex number in the Hexadecimal box, with or without 0x in front. FF is 255.

Does it work for very large numbers?

Yes. It uses exact whole-number maths, so there is no rounding, even for numbers with hundreds of digits.

Can I use negative numbers or fractions?

Negative whole numbers work with a minus sign. Fractions are not supported: this tool is for whole numbers.

Is anything sent to a server?

No. It is all calculated in your browser as you type.