Hex Calculator

Free online hex calculator to convert between hexadecimal and decimal numbers. Perform hex arithmetic operations with step-by-step calculation and explanation.

How to Calculate Hexadecimal?

Hexadecimal (base-16) is a number system that uses 16 symbols: 0-9 and A-F. It's commonly used in computer programming and digital systems. Each position represents a power of 16.

Converting Hexadecimal to Decimal:

  • Write down the hexadecimal number
  • Multiply each digit by 16 raised to the power of its position (from right to left, starting at 0)
  • Add all the results together

0xFF = 15×16¹ + 15×16⁰ = 240 + 15 = 255

Converting Decimal to Hexadecimal:

  • Divide the decimal number by 16
  • Write down the remainder (convert 10-15 to A-F)
  • Continue dividing the quotient by 16 until it becomes 0

255 ÷ 16 = 15 remainder 15 → F

15 ÷ 16 = 0 remainder 15 → F

Result: 0xFF

Hexadecimal reference table

DecimalHexadecimalBinary
00x00000
10x10001
100xA1010
150xF1111
160x1010000
2550xFF11111111
2560x100100000000