Hex to Binary and Decimal Converter
Type in any field and the other two update in real time. Binary is displayed grouped in nibbles (4-bit groups).
| Hex | Binary | Dec |
|---|
How the conversion works
The calculator uses decimal as an intermediate base for all conversions:
- Hex → Decimal: each digit is multiplied by its power of 16. For example,
FF= 15×16 + 15 = 255. - Decimal → Binary: successive division by 2. The result is zero-padded on the left to complete groups of 4 bits (nibbles).
- Binary → Hex: bits are grouped right-to-left in sets of 4 and each group is converted to one hex digit.
The tool accepts optional prefixes: 0x for hexadecimal and 0b for binary. Spaces within binary input are ignored automatically.
What is a nibble?
A nibble is 4 consecutive bits. A full byte (8 bits) has 2 nibbles. The exact nibble–hex digit correspondence is why hexadecimal is so useful in computing: one byte is expressed with just 2 hex characters instead of 8 binary digits.
Practical example: the colour #1A3C5E
The navy blue colour of this page in CSS is #1a3c5e. Each hex pair represents one colour channel (red, green, blue):
3C hex → 0011 1100 binary → 60 decimal (green)
5E hex → 0101 1110 binary → 94 decimal (blue)
This explains why hexadecimal is the standard for web colours: two hex digits represent exactly the 256 possible levels (0–255) of each RGB colour channel.
Frequently asked questions
How do you convert hexadecimal to binary?
What is hexadecimal used for in computing?
What is a nibble in binary?
How do you convert binary to decimal?
What is the difference between hexadecimal and binary?
Where does hexadecimal appear in everyday life?
Last updated
Converter updated in 2026. Supports positive integers up to 2⁵³ (JavaScript's safe integer limit for exact integer arithmetic).