Number Base Converter — Binary, Decimal, Hexadecimal & Octal
Convert numbers between binary, decimal, hexadecimal and octal online free — instant conversion with bitwise AND, OR, XOR and NOT operations. Essential tool for developers and students.
Last updated: June 2026
Bitwise operations
About this tool
Convert between number systems instantly
Computers think in binary, programmers read in hexadecimal, and people count in decimal — so converting between number bases is a daily task for developers, students and electronics hobbyists. This number base converter shows binary, octal, decimal and hexadecimal side by side: edit any one box and the other three update immediately, so you can see exactly how the same value looks in each system.
Beyond the four standard bases, a custom base field handles any base from 2 to 36, using the digits 0–9 followed by the letters A–Z for higher values — useful for base-32 encodings, base-36 short IDs and academic exercises. Invalid digits for the chosen base are flagged so you always know your input is well-formed.
For low-level work, the bitwise operations panel computes AND, OR, XOR, NOT and left/right shifts on two operands, showing each result in both decimal and binary. These operations are the foundation of bit flags, permission masks, colour channels and performance-critical code. Everything runs locally in your browser, so it's instant, free and private — nothing you type is uploaded anywhere.
How it works
Three quick steps — no account, nothing uploaded to a server.
Enter a value
Type into any base box — binary, octal, decimal or hex.
See all bases
The other systems update at the same time, plus a custom base.
Use bitwise ops
Compute AND, OR, XOR, NOT and shifts on two numbers.
FAQ
Frequently asked questions
How do I convert decimal to binary?
Type your decimal number into the Decimal box and the binary equivalent appears instantly in the Binary box (along with octal and hex). For example, 255 in decimal is 11111111 in binary. Under the hood it repeatedly divides by 2 and reads the remainders — the calculator just does it for you.
What do binary, octal, decimal and hex mean?
They're number systems with different bases: binary is base 2 (digits 0–1), octal is base 8 (0–7), decimal is base 10 (0–9, what we use day to day), and hexadecimal is base 16 (0–9 then A–F). The same value can be written in any of them — this tool shows all four at once.
Why is hexadecimal used for colors?
Hex is compact and maps neatly onto bytes: each pair of hex digits represents one byte (0–255), so a colour like #FF8800 encodes red, green and blue in two digits each. That's far shorter than writing the same values in binary or decimal, which is why CSS and design tools use hex.
Can I convert to bases other than 2, 8, 10 and 16?
Yes. The custom-base box lets you read or write a number in any base from 2 to 36 (using digits 0–9 and letters A–Z for values above 9). Change the base selector and the custom box updates to that base.
What are the bitwise operations for?
Bitwise AND, OR, XOR, NOT and bit shifts operate on the individual binary bits of a number — the building blocks of low-level programming, flags, masks and permissions. Enter two operands and the tool shows each result in decimal and binary, which is handy for developers and computer-science students.
Related tools
You might also need these.