Hexadecimal Number System
Last Updated :
14 Jul, 2025
The Hexadecimal system is a base-16 number system that plays an important role in computing and digital systems. It uses sixteen symbols to represent values:
Digits (0 to 9) and the letters A to F, where A = 10, B = 11, and so on up to F = 15.
Hexadecimal Number System TablePlace Value of Digits in the Hexadecimal Number System
The numbers in the hexadecimal number system have weightage in powers of 16. The power of 16 increases as the digit is shifted towards the left of the number. This is explained by the example as,
Example: (AB12)16
Place value of each digit in (AB12)16 is,
= A×163 + B×162 + 1×161 + 2×160
Conversion from Hexadecimal to Other Number Systems
Conversion of a number system means conversion from one base to another. Following are the conversions of the Hexadecimal Number System to other Number Systems:
Hexadecimal to Decimal Conversion:
To convert a hexadecimal number to decimal (base-10), multiply each digit by its corresponding power of 16 and sum the results.
Example: To convert (8EB4)16 into a decimal value

Follow the steps given below:
- Step 1: Write the decimal values of the symbols used in the Hex number i.e. from A-F
- Step 2: Multiply each digit of the Hex number with its place value. Starting from right to left i.e. LSB to MSB.
- Step 3: Add the result of multiplication and the final sum will be the decimal number.
Hexadecimal to Binary Conversion
Each hexadecimal digit corresponds to a 4-bit binary sequence. Convert each digit individually and combine.
Example: (B2E)16 is to be converted to binary

Follow the steps given below:
- Step 1: Convert the Hex symbols into their equivalent decimal values.
- Step 2: Write each digit of the Hexadecimal number separately.
- Step 3: Convert each digit into an equivalent group of four binary digits.
- Step 4: Combine these groups to form the whole binary number.
Hexadecimal to Octal Conversion:
Convert hexadecimal to binary, group the binary digits into sets of three (right to left), and convert each group to its octal equivalent.
Example: (B2E)16 is to be converted to hex

Follow the steps given below:
- Step 1: We need to convert the Hexadecimal number to Binary first. For that, follow the steps given in the above conversion.
- Step 2: Now to convert the binary number to an Octal number, divide the binary digits into groups of three digits starting from right to left i.e. from LSB to MSB.
- Step 3: Add zeros before MSB to make it a proper group of three digits(if required)
- Step 4: Now convert these groups into their relevant decimal values.
Decimal to Hexadecimal Conversion
Divide the decimal number by 16 repeatedly, noting remainders, until the quotient is 0. Read remainders in reverse order, using A–F for 10–15.

Related Articles:
Facts About Hexadecimal Numbers
- Hexadecimal is a number system with a base value of 16.
- Hexadecimal numbers use 16 symbols or digital values: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E, F.
- A, B, C, D, E, and F represent 10, 11, 12, 13, 14, and 15 in single-bit form.
- If you see an "0x" as a Prefix, it indicates the number is in Hexadecimal. For example, 0x3A
- The position of each digit in a Hexadecimal number has a weight of 16 to the power of its position.
Solved Examples on Hexadecimal Number System
Example 1: Convert Hexadecimal 1A5 to Decimal
Solution:
Multiply First Digit (1) by 16 squared (256)
1×162 = 256
Multiply Second Digit (A, which is 10 in decimal) by 16 to the power of 1 (16)
10×161 = 160
Multiply Third Digit (5) by 16 to the power of 0 (1)
5×160 = 5
Adding the results,
1A5 = 1×162 +A×161 + 5×160
⇒ 1A5 = 1×162 + 10×161 + 5×160
⇒ 1A5 = 256 + 160 + 5 = 421
Decimal Equivalent of Hexadecimal number 1A5 is 421
Example 2: Convert Decimal 315 to Hexadecimal.
Solution:
Divide Decimal Number by 16
315÷16 = 19 with Remainder 11
The remainder (11) is represented as B in hexadecimal
Repeat the division with the quotient (19)
19÷16 = 1 with Remainder of 3
The remainder (3) is represented as 3 in hexadecimal
Hexadecimal Equivalent of Decimal Number 315 is 13B
Example 3: Convert (1F7)16 to Octal.
Solution:
Step 1: Convert (1F7)16 to decimal using the powers of 16:
(1F7)16 = 1 × 162 + 15 × 161 + 7 × 160
⇒ (1F7)16 = 1 × 256 + 15 × 16 + 7 × 1
⇒ (1F7)16 = 256 + 240 + 7
⇒ (1F7)16 = (503)10
Step 2: Convert the decimal number (503)10 to octal by dividing it by 8 until the quotient is 0
503 ÷ 8 = 62 with a remainder of 7
62 ÷ 8 = 7 with a remainder of 6
7 ÷ 8 = 0 with a remainder of 7
Arrange the remainder from bottom to top
Therefore, (1F7)16 is equivalent to (767)8 in octal
Example 4: Convert (A7B)16 to decimal.
(A7B)16 = A × 162 + 7 × 161 + B × 160
⇒ (A7B)16 = 10 × 256 + 7 × 16 + 11 × 1 (convert symbols A and B to their decimal equivalents; A = 10, B = 11)
⇒ (A7B)16 = 2560 + 112+ 11
⇒ (A7B)16 = 2683
Therefore, the decimal equivalent of (A7B)16 is (2683)10.
Practice Questions on Hexadecimal Number System
Question 1: Convert the hexadecimal number 2A to binary.
Question 2: Convert the binary number 110110 to hexadecimal.
Question 3: Add the hexadecimal numbers 1F and A3. Provide the result in hexadecimal.
Question 4: Subtract the hexadecimal number B6 from D9. Provide the result in hexadecimal.
Question 5: Multiply the hexadecimal number 7E by 3. Provide the result in hexadecimal.
Answer Key
1. 101010
2. 36
3.C2
4.23
5.17A
Suggested Quiz
9 Questions
How many symbols are there in the Hexadecimal number system?
Explanation:
The hexadecimal number system has 16 unique symbols or numbers:
- Digits: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9
- Letters: A, B, C, D, E, F (representing 10 to 15 in decimal)
What is the hexadecimal equivalent of the decimal number 255?
Explanation:
To convert a decimal number (base-10) to hexadecimal (base-16), we repeatedly divide the decimal number by 16 and record the remainders.
- Divide 255 by 16:
Quotient = 15, Remainder = 15.The remainder, 15, is represented as F in hexadecimal. - Divide the quotient (15) by 16:
Quotient = 0, Remainder = 15.Again, the remainder, 15, is represented as F in hexadecimal.
Write the remainders from bottom to top: FF
If the color red is represented as #FF0000 in hexadecimal code, and 1010 (binary) is added to it, what is the hexadecimal code of the new color formed?
Explanation:
The binary 1010 converts to A in hexadecimal, which is added to the blue channel (00) of #FF0000, resulting in #FF000A.
Find the two's complement of (AF)16.
Explanation:
Decimal | 175 |
Binary | 1010 1111 |
Hex | AF |
1's Complement | 0101 0000 |
2's Complement | 0101 0001 |
What is the decimal value of (8AB)16 + (B78)16.
Explanation:
Covert Hex values to decimals:
8AB = 2219
B78 = 2936
Add the values
2219 + 2936 = 5155
The Logic XOR operation of (6AFD)16 and (CDF)16 is?
Explanation:
Convert Hexadecimal NUmbers to binary:
- Convert (6AFD)16: 0110 1010 1111 1101
- Convert (CDF)16: 0000 1100 1101 1111
Perform the XOR operation:
- Compare each bit of (6AFD)16 and (CDF)16:
Covert Binary back to Hexadecimal:
- 0110 = 6
- 0110 = 6
- 0010 = 2
- 0010 = 2
Hexadecimal result: 6622
Convert (5A1.C)16 to Octal.
Explanation:
Convert the hexadecimal to binary:
- 5: 0101
- A: 1010
- 1: 0001
- C: 1100
So, (5A1.C)16 = (0101 1010 0001.1100)2
Convert the binary number to octal:
Group the binary digits into sets of three, starting from the decimal point. Add leading or trailing zeros if necessary. ( 010 110 100 001.110 000 )
Now convert each group to octal:
- 010 corresponds to 2
- 110 corresponds to 6
- 100 corresponds to 4
- 001 corresponds to 1
- 110 corresponds to 6
- 000 corresponds to 0
So, the octal representation is (2641.6)8
If a hexadecimal number has n digits, what is the range of values it can represent?
Explanation:
For unsigned hexadecimal numbers, all n digits are used to represent the magnitude, Range of Values: 0 to (16n − 1)
Find the division of (70592)16 ÷ (80)16.
Explanation:
Convert the hexadecimal numbers to decimal
(70592)16:
- 7: 7 × 164 = 7 × 65536 = 458752
- 0: 0 × 163 = 0 × 4096 = 0
- 5: 5 × 162 = 5 × 256 = 1280
- 9: 9 × 161 = 9 × 16 = 144
- 2: 2 × 160 = 2 × 1 = 2
Total: 458752 + 0 + 1280 + 144 + 2 = 460178
(80)16:
- 8: 8 × 161 = 8 × 16 = 128
- 0: 0 × 160 = 0 × 1 = 0
Total: 128 + 0 = 128
Perform the division in decimal: 460178/128 ≅3595.141
3595 in decimal to hexadecimal: (E0B)16
Quiz Completed Successfully
Your Score : 2/9
Accuracy : 0%
Login to View Explanation
1/9
1/9
< Previous
Next >
Similar Reads
What is Hexadecimal Numbering ? Hexadecimal numbering is a basic and important concept in computing and digital electronics. The hexadecimal numbering system which is often abbreviated as "hex", is a much more condensed view than binary or decimal. This article will take you through the basics of the Hexadecimal numbering System -
7 min read
Number System in Maths Number System is a method of representing numbers with the help of a set of symbols and rules; it is a mathematical notation used to represent quantities or values in various forms. Please remember every piece of data in a computerâwhether itâs text, images, sound, video, code, or memory addressesâi
7 min read
Number System in Maths Number System is a method of representing numbers with the help of a set of symbols and rules; it is a mathematical notation used to represent quantities or values in various forms. Please remember every piece of data in a computerâwhether itâs text, images, sound, video, code, or memory addressesâi
7 min read
Binary Number System The Binary Number System, also known as the base-2 system, uses only two digits, '0' and '1', to represent numbers. It forms the fundamental basis for how computers process and store data. This base-2 system is the backbone of how computers process and store information, representing everything from
8 min read
Binary Number System The Binary Number System, also known as the base-2 system, uses only two digits, '0' and '1', to represent numbers. It forms the fundamental basis for how computers process and store data. This base-2 system is the backbone of how computers process and store information, representing everything from
8 min read
What is a Number System? A number system is a way of writing numbers using specific symbols or digits. It helps us represent numbers mathematically. There are different types of number systems, such as the decimal system, binary system, octal system, and hexadecimal system.Here, we will discuss the types of number systems i
4 min read