How to convert numbers between binary, decimal, octal and hex
Computers count in binary, programmers read hexadecimal, people use decimal. Number base converter shows all of them together.
Steps
- Choose the base your number is written in: decimal, binary, octal, hexadecimal or base 36.
- Type the number.
- Read it in every other base.
How the systems work
- Binary uses 0 and 1.
1010is 10. - Octal uses 0 to 7.
12is 10. - Decimal is everyday counting.
- Hexadecimal uses 0 to 9 and A to F.
FFis 255, which is why colours like#ff8800use it. See Color converter. - Base 36 uses 0 to 9 and A to Z, handy for short IDs.
Tips
- If you get an error, check that every digit is valid for the base:
2does not exist in binary. - Hex letters are not case sensitive.
- Very large numbers are handled with big-integer arithmetic, so they do not lose precision.