What the Number Base Converter does
The Number Base Converter shows a whole number in binary, octal, decimal, hexadecimal and one other base of your choice from 2 to 36, all at once. Type a number in any base; prefixes like 0x and 0b, spaces and underscores are understood. It works with numbers of any size, groups digits for easier reading, and for negative numbers shows the two’s complement bit pattern used by computers.
How to use it
- Type a number.
- Choose which base it is in.
- Read it in every other base, and copy any of them.
- Optionally choose another base to show, such as 36.
Example
255 in decimal is 1111 1111 in binary, 377 in octal and FF in hex. −42 is −0010 1010 in binary and −2A in hex, and stored as a signed 8-bit value it becomes 1101 0110, or 0xD6, in two’s complement.
Where bases show up
Hex is used for colours (#FF8800), memory addresses and byte values; binary for flags, permissions and networking masks; octal for Linux file permissions such as 755. Base 36 uses 0–9 and A–Z and is common for short IDs.
Numbers are handled exactly with big integers, so very long values such as 64-bit IDs or cryptographic numbers convert without rounding. Fractions are not supported.
Questions people ask
Is my data uploaded?
No. The conversion happens in your browser as you type, so data such as customer lists or keys never leaves your device.
What is two’s complement?
The way computers store negative whole numbers: the bits are flipped and one is added, so −1 in 8 bits is 1111 1111.
Why is binary padded with zeros?
It is grouped in fours (nibbles), and each hex digit equals one group, which makes the two easy to compare.
Are letters case sensitive?
No. ff and FF are the same in hex.
Can I convert a colour code?
Yes, one part at a time: FF from #FF8800 is 255 in decimal. For whole colours, a colour converter is quicker.