Number Base Converter
Convert numbers between binary, octal, decimal, hex, and any base from 2 to 36.
Frequently Asked Questions
Why do programmers use hexadecimal?+
Hexadecimal (base 16) is a compact representation of binary data. Because 16 = 2⁴, every hex digit maps exactly to 4 binary bits, and every byte (8 bits) is exactly 2 hex digits. This makes hex ideal for memory addresses, color codes, bitfields, and cryptographic hashes — all contexts where values ultimately live in binary hardware.
How are letters A–F used in hexadecimal?+
Hexadecimal needs 16 distinct digit symbols. After using 0–9 (10 digits), it borrows letters: A=10, B=11, C=12, D=13, E=14, F=15. The same pattern extends to higher bases — base 36 uses 0–9 and A–Z, which is why URL shorteners and identifiers often use base-36 strings.
What is octal used for in programming?+
Octal (base 8) is most commonly used for Unix/Linux file permissions, where each permission group (owner, group, others) maps to 3 bits — exactly one octal digit. The familiar chmod 755 command uses octal: 7 = rwx, 5 = r-x. Octal literals also appear in C and Python (0o755).
What is the largest base this tool supports?+
Base 36, which uses digits 0–9 and letters A–Z. This is the highest base JavaScript's built-in BigInt.prototype.toString() supports natively. Base 36 is widely used for compact, case-insensitive alphanumeric identifiers.
How to use
- Type a number into any field — all other bases update instantly.
- BIN accepts digits 0–1, OCT accepts 0–7, HEX accepts 0–9 and A–F.
- Use the Custom base field to pick any base from 2 to 36.
- Digits beyond 9 are represented as letters (A=10, B=11, … Z=35).