Table of Contents

Last modified on August 3rd, 2023

Hexadecimal (hex in short) to decimal is the process of converting hexadecimal numbers to decimal numbers. The hexadecimal number system is generally used to express larger numbers with fewer digits.

**Hexadecimal number system** consists of numbers with the base of 16. It has 16 notations starting from 0 to 15, where 10 to 15 are expressed with alphabets A to F.

In contrast, the **decimal number system** consists of numbers with the base of 10. It has 10 notations, starting from 0 to 9.

The table below represents the relation between the hexadecimal numbers with the decimal numbers.

Hexadecimal | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | A | B | C | D | E | F |

Decimal | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 |

Here, we will be using the same formula to convert a decimal to hexadecimal.

Decimal Number = d_{n-1} × 16^{r-1}+….+ d_{2} × 16^{2} + d_{1} × 16^{1} + d_{0} × 16^{0}

Here, n = number of digits, r = place of the digit

Now we will learn how to convert a hexadecimal number to a decimal number as shown in the example below.

Following the above example, let us solve some more examples.

**Convert (7EC) _{16} to decimal.**

Solution:

As we know,

In hexadecimal system, E = 14,

∴ (7EC)_{16} = (7 × 16²) + (14 × 16¹) + (12 × 16⁰) = 2028

Hence, (7EC)_{16 }= (2028)_{10}

**Express (2A1ED) _{16} to decimal.**

Solution:

As we know,

In hexadecimal system, A = 10, E = 14, D = 13**∴ **(2A1ED)_{ 16} = (2 × 16⁴) + (10 × 16³) + (1 × 16²) + (14 × 16¹) + (13 × 16⁰) = (172525)_{ 10}

A reference chart is shown below which can help us to convert hexadecimal to decimal or other numbers like binary.

Last modified on August 3rd, 2023