Binary to Hexadecimal Converter

Convert binary (base 2) to hexadecimal (base 16) by grouping 4 bits at a time. Each group is highlighted so you can see exactly how the conversion works.

Pro Tip: Need to convert between Decimal, Binary, Hex & Octal all at once? Open All-in-One Converter

How to Convert Binary to Hex

The trick is that 4 binary bits = 1 hex digit exactly, because 2⁴ = 16. So the conversion requires just grouping bits rather than complex division.

  1. Write the binary number
  2. Count digits from right — pad left with zeros to make a multiple of 4
  3. Split into groups of 4 bits
  4. Convert each group: 0000=0, 0001=1…1010=A, 1011=B…1111=F
  5. Write hex digits in order
Binary: 10110101
Group:  1011 | 0101
Hex:      B  |  5
Result: B5

4-bit to Hex Reference

0000 → 0
0001 → 1
0010 → 2
0011 → 3
0100 → 4
0101 → 5
0110 → 6
0111 → 7
1000 → 8
1001 → 9
1010 → A
1011 → B
1100 → C
1101 → D
1110 → E
1111 → F

Frequently Asked Questions

How do I convert binary to hexadecimal?
Group binary digits in sets of 4 from the right (pad with zeros if needed). Convert each group to its hex digit. Example: 10101111 → 1010|1111 → A|F → AF.
Why is hex easier to work with than binary?
Hex requires fewer digits — 1 hex digit = 4 binary bits. A 32-bit number needs 32 binary digits but only 8 hex digits. Hex is more compact and easier to read.
What is 11111111 in hex?
11111111 (8 ones) groups as 1111|1111 = F|F = FF in hex, which equals 255 in decimal.

Related Converters