Base converter — binary, octal, decimal and hexadecimal
Convert a number between binary, octal, decimal, hexadecimal, base 32 and base 36 — with invalid digits caught rather than silently ignored.
Runs entirely in your browser — nothing is uploaded.
11111111377255FF7V73How to use
- Enter your number. A 0x, 0b or 0o prefix is stripped automatically.
- Say which base it is in. Every other representation appears at once.
- Copy the one you need. Each row has its own copy button.
Questions
How do I convert binary to decimal by hand?
Each position is a power of two, read right to left. 1010 is (1×8) + (0×4) + (1×2) + (0×1) = 10.
Why is hexadecimal used so much in computing?
Because one hex digit maps exactly to four bits, so a byte is always exactly two hex digits. That makes binary data compact to write and easy to read back — which is why colours, memory addresses and hashes all use it.
What happens if I enter an invalid digit?
You get told which character is wrong. This matters: JavaScript’s own parseInt silently stops at the first invalid character, so parseInt("12x", 10) returns 12 rather than an error — a real source of bugs.
What is base 36?
Digits 0–9 followed by letters a–z, giving the most compact representation using only alphanumerics. It is common in short URLs and generated IDs.