Skip to content
SimpleConvertSimpleConvert

Decimal to Hexadecimal Converter

Convert decimal numbers (base 10) to hexadecimal (base 16) with base-16 division steps.

How to use it

  • Enter decimal number to calculate hexadecimal.

Examples

255FF
1610

Hexadecimal (base 16) is the number system programmers use to write memory addresses, byte values and color codes compactly, using digits 0-9 and letters A-F for values 10-15. To convert a decimal number to hex, divide repeatedly by 16 and read the remainders (converted to hex digits) from bottom to top.

Worked example

255 ÷ 16 = 15 remainder 15. 15 in hex is F, and the remainder 15 is also F, giving FF — the classic maximum byte value and why white is #FFFFFF in CSS.

16 ÷ 16 = 1 remainder 0. 1 ÷ 16 = 0 remainder 1. Reading bottom to top: 10. This is worth noting — decimal 16 becomes hex '10', not because it's ten, but because 16 is exactly one full 'hex hundred' (16¹).

Where this comes up

  • Building or checking CSS hex color codes (#RRGGBB) from decimal RGB values
  • Working with memory addresses, pointers or debugger output in programming
  • Computer science and networking coursework on number bases
Runs entirely in your browser. Nothing you type is uploaded, logged or shared.

Last updated 18 August 2026