This free online number system converter instantly converts any number between binary, octal, decimal, and hexadecimal, all at once. Enter a value, pick the base it's currently in, and see every equivalent representation right away.
Whatever base you start from, the tool first checks that every character is a legal digit for that base, then reads the input into a single whole-number value. That value is then written out four times: in base 2, base 8, base 10 and base 16. Hex letters can be typed in either case and are always shown in capitals in the result.
Every positional system works the same way: each digit is multiplied by the base raised to the power of its position, counting from 0 on the right. Hex 1F4, for instance, is 1 × 256 + 15 × 16 + 4 × 1 = 500.
Select Hexadecimal, enter 1F4 and convert. The results are decimal 500, binary 111110100 and octal 764. You can check the octal answer through binary: split 111110100 into threes from the right as 111 110 100, which reads 7, 6, 4.
Going from hex to octal by hand is easiest through binary rather than decimal. Write each hex digit as four bits, then regroup the bits in threes. Hex 3FA is 0011 1111 1010, which regrouped is 1 111 111 010, or octal 1772.
| Decimal | Binary | Octal | Hex |
|---|---|---|---|
| 7 | 111 | 7 | 7 |
| 8 | 1000 | 10 | 8 |
| 10 | 1010 | 12 | A |
| 15 | 1111 | 17 | F |
| 16 | 10000 | 20 | 10 |
| 64 | 1000000 | 100 | 40 |
| 100 | 1100100 | 144 | 64 |
| 255 | 11111111 | 377 | FF |
| 256 | 100000000 | 400 | 100 |
| 1000 | 1111101000 | 1750 | 3E8 |
Notice that "10" means a different amount in each system: two in binary, eight in octal, ten in decimal and sixteen in hex. When writing numbers for others, label the base, for example with a subscript or a prefix like 0x for hex.
The tool handles non-negative whole numbers. Exact results are guaranteed up to 9007199254740991 in decimal (1FFFFFFFFFFFFF in hex); beyond that the last digits may be rounded.