Number Base Converter — BIN, DEC, HEX

Binary, octal, decimal and hexadecimal.

BIN
OCT
DEC
HEX
BASE 36

The number base converter translates a number between binary (BIN), octal (OCT), decimal (DEC), hexadecimal (HEX), and BASE36. Type a value into any field and the other representations update instantly. Prefixes 0b, 0o, and 0x are accepted.

Converting between bases comes up constantly for programmers and students alike: HEX is used for web colors (#ff8800), memory addresses, bytes, and bitmasks; BIN is used for bitwise operations, flags, and logic; BASE36 (digits plus letters) is handy for short identifiers. For example, decimal 255 is 0xFF in HEX and 11111111 in binary.

Everything is calculated right in your browser, instantly, with no data sent anywhere. It's a handy companion for debugging, learning computer science, and working with low-level data.

Frequently asked questions

BIN represents how machines store data and is used for bitwise operations. HEX is a compact way to write binary data (1 byte = 2 hex digits). OCT is largely outdated but still shows up in Unix permissions (chmod 755). BASE36 is used for short, readable IDs.
Hex uses digits 0-9 plus a-f (16 symbols), while base36 uses 0-9 plus a-z (36 symbols). Base36 produces shorter strings for large numbers.
Yes. For binary, octal, and hexadecimal, negatives are shown with a minus sign in front of the number, not as two's complement.
Yes. It uses BigInt internally, so numbers of any length (even thousands of digits) work fine.