Convert between binary (base 2), octal (base 8), decimal (base 10), and hexadecimal (base 16). Enter any value and instantly see all four representations with conversion steps.
Multiply each binary digit by 2 raised to its position (right to left, starting at 0), then sum. For 1011: (1×8)+(0×4)+(1×2)+(1×1) = 11 in decimal.
Repeatedly divide by 2 and record remainders. Read remainders from bottom to top. For 13: 13÷2=6r1, 6÷2=3r0, 3÷2=1r1, 1÷2=0r1. Binary = 1101.
Hex (base 16) represents binary data compactly — each hex digit represents exactly 4 binary bits. Memory addresses, color codes (#FF5733), error codes, and network addresses use hex because it is more readable than binary.
Each hex digit has a positional value based on powers of 16. For FF: (15×16)+(15×1) = 240+15 = 255. This converter handles the calculation automatically. Click any result to copy it.
Octal (base 8) uses digits 0-7. It was historically used in computing because 3 binary bits map to one octal digit. Unix file permissions use octal: chmod 755 = 111 101 101 in binary.
Binary corresponds to two physical states in electronics: off (0) and on (1). Digital circuits detect voltage levels — low voltage is 0, high voltage is 1. All digital data is ultimately stored and transmitted as binary.
n bits can represent 2ⁿ values (0 to 2ⁿ-1). 4 bits: 16 values (0-15). 8 bits (1 byte): 256 values (0-255). 16 bits: 65,536 values. 32 bits: about 4.3 billion values.