- Binary to Hexadecimal Conversion Definition: Converting a binary number to a hexadecimal number involves dividing the binary digits into groups of four, converting each group to decimal, and then to hexadecimal.
- Padding Zeros: When converting, pad groups of binary digits with zeros on the left if they have fewer than four digits.
- Binary to Hexadecimal Conversion Example: For example, the binary number 100010100101₂ converts to hexadecimal as 8A5₁₆.
- Hexadecimal to Binary Conversion Definition: Converting a hexadecimal number to a binary number involves converting each hexadecimal digit to a four-digit binary equivalent.
- Hexadecimal to Binary Conversion Example: For example, the hexadecimal number 3DC₁₆ converts to binary as 001111011100₂.
Understanding different number systems is a crucial part of learning digital electronics. We have previously discussed various number systems and their interrelations. Now, let’s explore the relationship between binary and hexadecimal systems. Converting between these systems is straightforward, and we will cover both binary to hexadecimal and hexadecimal to binary conversions in this article.
Binary to Hexadecimal Conversion
Just as you can convert any binary numbers to decimal, or convert binary numbers to octal, any number in the binary number system can be converted into the hexadecimal number system.
To convert a binary number to hexadecimal, divide the digits of the binary number into groups of four, starting from the right. If the last group has fewer than four digits, pad it with zeros on the left.
Next, convert each group of four binary digits into its decimal equivalent and then to its hexadecimal representation. Write these hexadecimal digits side by side to get the final hexadecimal number.
We take any binary number suppose 1000101001012.
Breaking it into groups of 4 we get
1000|1010|0101
Now converting all the groups into decimal numbers individually we get
8 | 10 | 5
So the desired hexadecimal equivalent of the binary number 1000101001012 is 8A516
Hexadecimal to Binary Conversion
Converting from hexadecimal to binary is also straightforward. Each hexadecimal digit can be directly converted to its four-digit binary equivalent. Pad with zeros on the left if needed to make each group four digits.
Combine all the four-digit binary groups to form the final binary number equivalent to the hexadecimal number. Let’s understand this method with an example.
3DC16 is the hexadecimal number which we want to convert into binary. We know D and C are equivalent to 13 and 12 respectively in decimal number system.
Now converting each digit into its binary equivalent number we get
0011|1101|1100
Now merging all these groups binary numbers to make the final binary number we get 11110111002 which is the binary equivalence of the hexadecimal number 3DC16





