Binary to Hex Calculator

Enter a binary number (0s and 1s) to convert it to hexadecimal.

How to Convert Binary to Hex

Method: group by 4 bits

Group the binary digits into sets of 4 from the right (pad with leading zeros if needed). Convert each group to its hex digit.

Example: 11111111 → 1111 1111 → F F → FF

4-bit groups (nibbles)

BinaryHexDecimal
000000
010155
100199
1010A10
1111F15

Related Calculators

Why Binary and Hex Are Related

Hexadecimal (base-16) is a compact shorthand for binary. Since 16 = 2⁴, each hex digit maps exactly to 4 binary digits (a nibble). This makes conversion trivial: split the binary into groups of 4 from the right, then convert each group to its hex digit. For example, binary 10111100 splits into 1011 | 1100 = B | C = 0xBC. Programmers use hex because it is far more readable than long binary strings — colour codes (#FF5733), memory addresses (0x7FFF), and assembly opcodes are all written in hex.

Binary to Hex Conversion Table

BinaryHexDecimal
000000
010155
100199
1010A10
1111F15

How to Convert Binary to Hexadecimal

Converting binary to hexadecimal is straightforward because 16 = 2⁴ — each hex digit corresponds to exactly four binary digits (a nibble). Group the binary number into blocks of four from the right (pad with leading zeros if needed), then convert each group to its hex equivalent. For example, 10110111 becomes 1011 0111 → B7 in hex. This grouping makes hex a compact human-readable shorthand for binary data.

Hexadecimal is widely used in programming, debugging, and color codes. RGB colors (#FF5733) are three hex pairs each representing an 8-bit value. Memory addresses in debuggers are shown in hex. Assembly language uses hex for opcodes. Once you know the 16 nibble→hex mappings (0–9 and A–F), you can mentally convert binary to hex faster than any other base.

Nibble (4-bit) to Hex Mapping

BinaryHexDecimal
000000
000111
001022
001133
010044
010155
011066
011177
100088
100199
1010A10
1011B11
1100C12
1101D13
1110E14
1111F15

Converting Binary to Hexadecimal Using Nibbles

The most efficient way to convert binary to hexadecimal is the nibble method. A nibble is a group of exactly four binary digits. Because 2 raised to the power 4 equals 16, each nibble maps directly and uniquely to a single hexadecimal digit. To perform the conversion, start from the rightmost bit of the binary number and group the digits into sets of four moving left. If the leftmost group has fewer than four digits, pad it with leading zeros. Then replace each four-bit group with its hexadecimal equivalent using the standard mapping (0000 = 0 through 1111 = F). For example, the binary number 10110100 splits into nibbles 1011 and 0100, which map to B and 4 respectively, giving a hexadecimal result of B4. This nibble method is fast, requires no arithmetic, and works for binary numbers of any length. Programmers and hardware engineers use it constantly when interpreting memory dumps, CPU registers, network packet headers, and color values in web and graphics applications where hexadecimal notation is standard.

Nibble to Hexadecimal Reference Table

Binary nibbleHexDecimal
000000
000111
001022
010044
100088
1010A10
1100C12
1111F15
Have Feedback or a Suggestion? Contact Us
Top