Hexadecimal to decimal converter
Convert hexadecimal to decimal with BigInt and view each digit’s contribution (16^n) with a running total. Includes binary and octal outputs with grouping options.
Hex to Decimal Calculator Online (Step-by-Step)
Convert hex to decimal with instant validation, base-16 steps, and binary/octal equivalents. Same clean vertical layout as the binary-decimal tool.
Decimal
—
Normalized hex
—
Binary
—
Octal
—
Automatic steps: powers of 16
Digit Position 16^pos
| Digit | Position | 16^position | Contribution | Cumulative total |
|---|
How to convert hex to decimal
Base 16 uses digits 0–9 and letters A–F. Each symbol is weighted by 16^position; count positions from right to left starting at 0.
- Clean and normalize. Strip the
0xprefix, spaces, or underscores; uppercase and lowercase are equivalent. - Map the digits. A=10, B=11, C=12, D=13, E=14, F=15; all other characters keep their decimal value.
- Assign positions. The rightmost digit is position 0, the next is 1, and so on as you move left.
- Multiply and add. Compute
digit × 16^positionfor each column and accumulate the contributions to get the decimal. - Verify equivalents. Use the binary (grouped in 4 bits) or octal outputs to double-check the conversion.
0xA → 10
0x1F → 31
0x7B → 123
0x2AF3 → 10995
FAQ
You can enter 0–9 and A–F with an optional
0x prefix. Spaces or underscores are removed automatically, and casing does not matter.
Yes. We rely on
BigInt to keep precision for long hex strings and for their decimal, binary, and octal equivalents.
They format the output: choose uppercase or lowercase for normalized hex and group the binary in blocks of 4 or 8 bits for easier reading.
This tool focuses on unsigned integers. It does not parse decimal parts or a leading minus sign; for signed values, convert the magnitude and apply sign logic or use the decimal-to-hex calculator.