calculator guides

How to Convert Hexadecimal to Decimal Manually - Full Guide

How to convert hexadecimal to decimal manually step by step - a complete guide covering the positional notation method, worked examples, and hex to binary conversion.

How to Convert Hexadecimal to Decimal Manually - Full Guide

How to convert hexadecimal to decimal manually step by step is a fundamental skill for anyone working with computers, programming, digital electronics, or web design. Hexadecimal (base-16) is the compact shorthand that programmers use to represent binary data - HTML colour codes like #FF6B35, memory addresses like 0x7FFE4B3A, and network packet headers are all written in hex. Use our free Hex Calculator to convert instantly, or follow this guide to understand the manual process.

What Is Hexadecimal?

Hexadecimal is base-16. Unlike decimal (base-10, digits 0-9) or binary (base-2, digits 0-1), hexadecimal uses 16 distinct symbols:

  • 0-9: Same values as decimal (0 through 9)
  • A-F: Represent values 10 through 15

| Hex | A | B | C | D | E | F | |-----|---|---|---|---|---|---| | Decimal | 10 | 11 | 12 | 13 | 14 | 15 |

Hexadecimal is used in computing because one hex digit represents exactly 4 binary digits (a nibble). Two hex digits represent 8 binary digits (one byte). This makes hex a compact, readable shorthand for binary values that would otherwise be extremely long.

The Positional Notation Method

Just like decimal numbers have positional values (units, tens, hundreds...) based on powers of 10, hexadecimal has positional values based on powers of 16.

Powers of 16: | Position | 4 | 3 | 2 | 1 | 0 | |----------|---|---|---|---|---| | Value | 65,536 | 4,096 | 256 | 16 | 1 |

Method:

  1. Write the hex number with positions numbered from 0 (rightmost)
  2. Replace each hex letter with its decimal value (A=10, B=11, etc.)
  3. Multiply each digit by 16 raised to its position
  4. Sum all the products

Worked Examples

Example 1: Convert 2F₁₆ to Decimal

| Digit | F | 2 | |-------|---|---| | Position | 0 | 1 | | Decimal value | 15 | 2 | | Power | 16⁰ = 1 | 16¹ = 16 | | Product | 15 × 1 = 15 | 2 × 16 = 32 |

Sum: 15 + 32 = 47₁₀

Verification: 2F₁₆ = 47₁₀ ✓

Example 2: Convert 1A3₁₆ to Decimal

| Digit | 3 | A | 1 | |-------|---|---|---| | Position | 0 | 1 | 2 | | Decimal value | 3 | 10 | 1 | | Power | 1 | 16 | 256 | | Product | 3 | 160 | 256 |

Sum: 3 + 160 + 256 = 419₁₀

Example 3: Convert FF₁₆ to Decimal

| Digit | F | F | |-------|---|---| | Position | 0 | 1 | | Decimal value | 15 | 15 | | Power | 1 | 16 | | Product | 15 | 240 |

Sum: 15 + 240 = 255₁₀

This is why 255 is written as FF in HTML colours - it's the maximum value of an 8-bit number (two hex digits).

Example 4: Convert FFFF₁₆ to Decimal

| Digit | F | F | F | F | |-------|---|---|---|---| | Position | 0 | 1 | 2 | 3 | | Product | 15 | 240 | 3,840 | 61,440 |

Sum: 15 + 240 + 3,840 + 61,440 = 65,535₁₀

This is the maximum value of a 16-bit unsigned integer (2¹⁶ − 1).

How to Convert Decimal to Hexadecimal

Use repeated division by 16, recording remainders and converting values 10-15 to A-F:

Example: Convert 255₁₀ to Hex

| Division | Quotient | Remainder | Hex Digit | |----------|----------|-----------|-----------| | 255 ÷ 16 | 15 | 15 | F | | 15 ÷ 16 | 0 | 15 | F |

Read from bottom to top: FF₁₆

Example: Convert 1,000₁₀ to Hex

| Division | Quotient | Remainder | Hex Digit | |----------|----------|-----------|-----------| | 1000 ÷ 16 | 62 | 8 | 8 | | 62 ÷ 16 | 3 | 14 | E | | 3 ÷ 16 | 0 | 3 | 3 |

Read from bottom to top: 3E8₁₆

How to Convert Hex to Binary

Since each hex digit = exactly 4 binary digits, replace each hex digit with its 4-bit binary equivalent:

Example: Convert 3C₁₆ to Binary

| Hex digit | 3 | C | |-----------|---|---| | Binary (4 bits) | 0011 | 1100 |

3C₁₆ = 00111100₂ = 60₁₀

Hex to Binary Lookup Table

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

Hexadecimal in the Real World

HTML Colour Codes

Every HTML/CSS colour is 6 hex digits: #RRGGBB

  • #FF0000 = Red (R=255, G=0, B=0)
  • #00FF00 = Green
  • #0000FF = Blue
  • #FFFFFF = White (all channels at maximum = 255)
  • #000000 = Black (all channels at zero)
  • #1A73E8 = Google Blue (R=26, G=115, B=232)

To decode any web colour: split into three 2-digit hex pairs and convert each to decimal for the RGB value.

Memory Addresses and Debugging

Modern computers display memory addresses in hex. A 64-bit address like 0x7FFEADBC1200 represents:

  • 0x prefix = indicates hexadecimal
  • The number itself = 7FFE ADBC 1200₁₆

Displaying memory addresses in decimal would be unwieldy - hex provides a compact, structured alternative.

Hash Values and Checksums

Cryptographic hashes (MD5, SHA-1, SHA-256) are expressed in hexadecimal. A SHA-256 hash is 64 hex characters = 256 binary bits = 32 bytes.

Network Protocols

MAC (Media Access Control) addresses - the unique identifiers for network interfaces - are written as 12 hex digits: 00:1A:2B:3C:4D:5E.

Our free Binary Calculator converts between binary, decimal, and hex in a single step.

Frequently Asked Questions

What is the positional value of the rightmost hex digit? 16⁰ = 1. The rightmost digit represents units. The next position is 16¹ = 16, then 16² = 256, then 16³ = 4,096, and so on.

How do you handle hex letters (A-F) in conversion? Replace each with its decimal equivalent: A=10, B=11, C=12, D=13, E=14, F=15. Then apply the positional notation method as normal.

Why do programmers prefer hex over decimal? Because each hex digit represents exactly 4 binary digits (one nibble), hex is a compact and structured representation of binary data - the native language of computers. Two hex digits = one byte (8 bits).

What does 0xFF equal in decimal? 0xFF₁₆ = 255₁₀. The 0x prefix is programming notation indicating a hexadecimal number. FF₁₆ = (15 × 16) + 15 = 240 + 15 = 255.

Is hex the same as base-16? Yes - hexadecimal literally means "16." It is base-16 positional notation, using digits 0-9 and letters A-F.

Sources & Further Reading

RECOMMENDED TOOL

Ready to calculate?

Open Hex Calculator
#hexadecimal#decimal#binary#hex conversion#computer science