Skip to content

Menu

Hex to Decimal

Convert hex to decimal and other bases

Runs entirely in your browserMath & FinanceFree, no sign-up
Loading tool

01What is Hex to Decimal?

This converter takes one whole number in hex, decimal, octal or binary and shows it in all four bases at once. Pick the input base with the four buttons, type into the Input box, and the results list fills in as you type. The base you picked gets a shaded row so you can tell input from output. The parsing is careful about prefixes. It only strips the prefix that belongs to the base you chose: 0x for hex, 0o for octal and 0b for binary. Decimal has no prefix. That sounds fussy, but it fixes a real trap. In hex, 0B1F is a perfectly valid number (2847), and a converter that blindly stripped every 0b would read it as binary 1F and give you 31. After that, the value goes through JavaScript's BigInt, which follows the numeric literal rules in the ECMAScript spec. BigInt has no 53-bit ceiling like Number and parseInt do. So 64-bit addresses, snowflake IDs and long hash values convert exactly. FFFFFFFFFFFFFFFF comes back as 18446744073709551615, with no rounding at the end. A quick worked case. Choose octal and type 755, the chmod value you see all the time. The list shows hex 0x1ED, decimal 493, octal 0o755 and binary 0b111101101. Read the binary in groups of three and you get 111, 101, 101, which is rwx, r-x, r-x. Output formatting is fixed. Hex is uppercase with 0x, octal gets 0o, binary gets 0b, and decimal is plain digits. Copy All puts all four on separate labelled lines, without those prefixes, which pastes nicely into a ticket or notes file. Now the limits. The tool handles non-negative integers only. A minus sign, a decimal point, a space in the middle or a digit that does not belong to the base (G in hex, 2 in binary, A in decimal) makes the results list disappear rather than guess. There is no two's complement view, so you cannot ask what FFFFFFFF means as a signed 32-bit value. Leading zeros are not kept in the output either. The conversion is plain JavaScript running in the page, so the numbers you paste stay in your browser tab.

Embedded and systems programmers reading registers, addresses and permission bits who need exact conversions of large values. The tool runs entirely in your browser, so your data never leaves your device.

02How to use Hex to Decimal

  1. Click hex, decimal, octal or binary to set the input base. The label changes to Input (hex) and so on.
  2. Type or paste the number into the Input box. The matching prefix, like 0x for hex, is optional.
  3. Read the four rows in the results list. Your input base is the shaded one.
  4. If no results appear, check for a minus sign, a space or a digit that is invalid in that base.
  5. Click Copy All for a labelled four-line summary, or the reset button to clear the input.

03Worked examples

Input: FF (hex)
Result: 0xFF 255 0o377 0b11111111
One byte with every bit set.
Input: 0x3B82F6 (hex)
Result: 0x3B82F6 3900150 0o16701366 0b1110111000001011110110
The 0x prefix is stripped before parsing.
Input: 0B1F (hex)
Result: 0xB1F 2847 0o5437 0b101100011111
Only the hex prefix 0x is removed in hex mode, so 0B1F is read as a hex number, not as binary 1F.
Input: 755 (octal)
Result: 0x1ED 493 0o755 0b111101101
The chmod 755 bits: 111 101 101.
Input: FFFFFFFFFFFFFFFF (hex)
Result: 18446744073709551615
Decimal row only shown. Exact 2^64 - 1, no precision loss.
Input: -5 (decimal)
Result: No results shown
Negative numbers are rejected rather than converted.

04Common use cases

  • Turning a hex address from a crash log or debugger, like 7FFFFFFF, into decimal to compare with a limit in the docs.
  • Converting a CSS colour such as 3B82F6 into the single integer some graphics or charting APIs expect.
  • Reading chmod 755 as binary to see exactly which read, write and execute bits are set.
  • Decoding a register value from a microcontroller datasheet written in hex into its individual bits.
  • Converting a 64-bit ID or bitmask without the rounding you get from parseInt or a spreadsheet.
  • Checking homework answers for a computer architecture course across all four bases at once.

05Tips

  • Picking a sample from the examples menu switches the base back to hex, so re-select your base afterwards if you were working in another one.
  • Each hex digit is exactly four bits, so a 16-digit hex value is a full 64-bit number.
  • Leading zeros vanish in the output. Pad binary results yourself when you need a fixed width like 8 or 32 bits.
  • Copy All writes the values without the 0x, 0o and 0b prefixes, so add them back if you paste into source code.

06Related concepts

Hexadecimal, Number bases, BigInt, Binary, Octal, Two's complement.

Frequently Asked Questions

What is Hex to Decimal?

Hex to Decimal is a free, browser-based developer tool on AIDToolStack. Convert hex to decimal and other bases It requires no installation or sign-up and works entirely in your browser.

Is Hex to Decimal free to use?

Yes. No sign-up, no fees and no usage cap.

Does Hex to Decimal store my data?

No. It runs in your browser; nothing is uploaded.

Reviews and commentsShow

Reviews

Sign in to leave a review.

Loading reviews…

Comments

Sign in to leave a comment.

Loading comments…

What changed in AI dev tools, once a month

Renames, shutdowns, pricing changes and new MCP setups, each with a source.

Subscribe