Number base converter
Enter a value in any common base and see it in all the others simultaneously, along with how many bits it needs.
How to use the number base converter
- Type the value.
- Tell it which base you typed in.
- Read the binary, octal, decimal, hex and base 36 forms together.
How it works
A positional base expresses a number as a sum of powers of that base. Hexadecimal is popular in programming because one hex digit maps exactly to four binary digits, so a byte is always two hex characters and the conversion is mechanical.
Prefixes are stripped automatically, so 0xFF, 0b1010 and plain digits all parse correctly.
Common questions
What is 255 in hexadecimal?
FF — which is why it is the maximum value of a single byte and the top of each RGB colour channel.
How many bits does a number need?
The bit length row shows it: the number of binary digits in the value.