How to convert hex to decimal
- Type or paste a hexadecimal number. A
0xprefix, spaces and lowercase letters are fine. - The decimal value appears at the top, with binary and octal below.
Doing it by hand
Each hex digit is worth a power of 16: 1, 16, 256, 4096, 65536… from the right. Convert letters to numbers (A = 10, B = 11, C = 12, D = 13, E = 14, F = 15), multiply each digit by its place value and add. For 1A3F: 1×4096 + 10×256 + 3×16 + 15×1 = 4096 + 2560 + 48 + 15 = 6719.
| Hex | Decimal |
|---|---|
| A | 10 |
| F | 15 |
| 10 | 16 |
| 1F | 31 |
| 40 | 64 |
| 7F | 127 |
| FF | 255 |
| 100 | 256 |
| 3E8 | 1000 |
| FFFF | 65535 |
| 7FFFFFFF | 2147483647 |
| FFFFFFFF | 4294967295 |
To read a CSS color, split it into pairs: #1E90FF is 1E (30) red, 90 (144) green and FF (255) blue. Windows error codes such as 0x80070005 and memory addresses are also hex; the converter handles 64-bit and longer values exactly. If a value was meant as a signed 32-bit number, anything from 80000000 upwards represents a negative value in two's complement.
FAQ
What is FF in decimal?
255.
What does 0x mean?
It is a prefix used in programming to show that a number is hexadecimal. It is not part of the value.
How do I convert a hex color to RGB?
Convert each pair of digits separately: #FF8800 → 255, 136, 0. The color converter shows all formats at once.