Number Base Converter

Convert numbers between binary, octal, decimal, and hexadecimal in real time.

Common Conversions

DecimalBinaryOctalHex
0000
1111
21022
31133
410044
510155
611066
711177
81000108
91001119
10101012A
11101113B
12110014C
13110115D
14111016E
15111117F
16100002010
321000004020
64100000010040
1281000000020080
25511111111377FF
256100000000400100
1024100000000002000400

About Number Bases

Number bases (or radixes) define how many unique digits are used to represent numbers. Binary (base 2) uses only 0 and 1 and is the foundation of all digital computing. Octal (base 8) was historically used in early computing systems. Decimal (base 10) is the standard system in everyday life. Hexadecimal (base 16) is widely used in programming because it provides a compact representation of binary data — one hex digit maps to exactly four binary digits.

FAQ

How do I convert binary to decimal?

Each binary digit represents a power of 2, starting from the right. For example, 1011 in binary = 1×2³ + 0×2² + 1×2¹ + 1×2⁰ = 8 + 0 + 2 + 1 = 11 in decimal.

Why is hexadecimal used in programming?

Hexadecimal is popular because each hex digit corresponds to exactly 4 binary bits. This makes it easy to represent large binary values compactly — for example, the byte 11111111 is simply FF in hex.

What is octal used for?

Octal is commonly used in Unix/Linux file permissions (e.g., chmod 755) and was historically used in older computing systems. Each octal digit represents exactly 3 binary bits.

Can this tool handle very large numbers?

Yes. This converter uses BigInt internally, so it can accurately convert numbers of arbitrary size without precision loss.

What characters are valid for each base?

Binary: 0 and 1. Octal: 0–7. Decimal: 0–9. Hexadecimal: 0–9 and a–f (case-insensitive).