Developer tools

Hex to Decimal Converter

Hex to Decimal Converter

Convert hexadecimal to decimal exactly, with signed readings for 8–128-bit values.

About this tool

About Hex to Decimal Converter

Paste a hexadecimal value, from a memory address, a colour channel, an error code like 0x80070005 or a 64-bit ID, into the Hexadecimal row and read its decimal value instantly. Upper and lower case digits, a 0x prefix and spaces between bytes are all accepted. Because the conversion uses arbitrary-precision integers, long values such as hash prefixes or 128-bit identifiers convert exactly, digit for digit. Hex values from low-level code are often signed: a Windows HRESULT, a status register or a two-byte sensor reading. Pick the width in the Two's complement panel and see the value read as both signed and unsigned, so 0xFFFE becomes 65534 or −2 depending on how the field is defined. The same page shows binary, octal and base 36, and you can type into the decimal row to convert decimal back to hex.

Built and maintained by Abhi JainUpdated

How to Convert Hex to Decimal

  1. 1

    Enter the hex value

    Type or paste it into the Hexadecimal row, with or without 0x.

  2. 2

    Read the decimal

    The Decimal row shows the value. For signed fields, choose a Bit width in the Two's complement panel and read As signed.

Hex to Decimal Converter: questions and answers

How do you convert hex to decimal?

Multiply each hex digit by 16 raised to its position from the right and add them, with A=10 through F=15. For 1F4: 1×256 + 15×16 + 4 = 500.

What is 0xFF in decimal?

255. Each hex digit is 4 bits, so FF is 8 bits all set to 1. As a signed 8-bit value it is −1.

Why is my hex value negative in some tools?

Those tools read it as a signed two's complement number. If the top bit of the chosen width is 1, the signed value is the unsigned value minus 2^n. Choose the width that matches your data type.

Is hex case-sensitive?

No. 0xff, 0xFF and 0xFf are the same number. Uppercase letters is just a display preference.