Binary Converter
Convert between binary, decimal, octal and hexadecimal number systems.
Number Systems - A Quick Breakdown
- Binary (Base 2) - Just 0s and 1s. Every single thing your computer does comes down to binary at the hardware level. One byte is 8 binary digits.
- Decimal (Base 10) - The system you grew up with. Ten digits, 0 through 9. Nothing fancy here.
- Octal (Base 8) - Uses digits 0-7. You'll mostly run into this when dealing with Unix file permissions like chmod 755.
- Hexadecimal (Base 16) - Uses 0-9 plus A through F. Programmers love it because each hex digit maps cleanly to 4 binary bits. That's why memory addresses and color codes use hex.
Where You'll Actually Use This
Web developers convert hex to decimal for CSS color values all the time. Network engineers need binary for IP subnetting - figuring out subnet masks like 255.255.255.0 means working in binary. Programmers deal with hex when reading memory dumps or debugging low-level code.
Quick Conversion Tips
To convert decimal to binary by hand, keep dividing by 2 and track the remainders. Read them bottom to top and that's your binary number. For hex to binary, just replace each hex digit with its 4-bit equivalent. F becomes 1111, A becomes 1010 and so on. Memorizing the powers of 2 up to 128 (1, 2, 4, 8, 16, 32, 64, 128) makes everything faster.
Common Values Worth Memorizing
A single byte holds values from 0 to 255 (or 00 to FF in hex). 2^10 is 1,024 - that's a kilobyte. 2^16 is 65,536 and 2^32 is about 4.29 billion. These numbers pop up constantly in programming.
How to Use
- Type your number into the input field.
- Select the base of your number (binary, decimal, octal or hex).
- All conversions appear instantly below.
- Click copy on the value you need.
Frequently Asked Questions
How do I read a binary number?
Each position represents a power of 2, starting from the right. So 1010 in binary is (1x8) + (0x4) + (1x2) + (0x1) = 10 in decimal. Think of it like decimal but with only two digits.
Why do programmers use hexadecimal instead of binary?
Binary gets really long really fast. One byte is 8 binary digits but only 2 hex digits. So FF is way easier to read than 11111111. Each hex digit maps to exactly 4 bits, making the conversion simple.
What's the fastest way to learn binary conversion?
Memorize the powers of 2 from 1 to 128 (1, 2, 4, 8, 16, 32, 64, 128). Practice with small numbers daily. The Cisco Binary Game is a popular free tool that many CS students swear by.
Why does my converter give wrong results for large numbers?
This usually happens in programming when you use floating-point math or a variable that's too small. A 16-bit integer maxes out at 65,535. If your number is bigger, you need 32-bit or 64-bit storage.
What's the difference between signed and unsigned binary?
Unsigned binary only represents positive numbers (0 to 255 for 8 bits). Signed binary uses the first bit to indicate positive or negative, so 8 bits gives you -128 to 127 instead.