Number Base Converter
Convert numbers between binary, octal, decimal and hexadecimal.
Non-negative whole numbers only. Enter digits valid for the chosen base (hex allows A–F).
Same number, different alphabets
A number’s value never changes — only how we write it. Each base uses a different set of digits and a different place value, so 255, 11111111 and FF all describe exactly the same quantity.
base 2 → 0,1 · base 8 → 0–7 · base 10 → 0–9 · base 16 → 0–9, A–F
The converter reads your value in its stated base, turns it into a plain number, and rewrites it in the others. Hexadecimal and binary are especially close — every hex digit is exactly four bits.
The decimal number 255 is 11111111 in binary, 377 in octal and FF in hexadecimal — a single byte at its maximum value.
Why bases matter
Computers work in binary because circuits are naturally on or off. People find long binary strings hard to read, so hexadecimal provides a compact shorthand — common in colour codes, memory addresses and low-level programming. Octal turns up in older systems and file permissions.
Handy to know
- One hex digit = four bits. Two hex digits make a byte (0–255).
- Powers of two. Binary place values double: 1, 2, 4, 8, 16…
- Colour codes. Web colours like #FF8800 are three hex bytes.