How to Convert Between Binary, Hex, and Decimal in Excel
Excel has DEC2HEX, HEX2DEC, DEC2BIN and the rest — but DEC2BIN caps out at 511, and converting binary straight to hex means nesting functions. Here's the one-click way that handles any base pair with no length limit.
Last updated: August 2026
| Value | Converted | |
|---|---|---|
| 255 (dec) | → | FF (hex) |
| 1010 (bin) | → | 10 (dec) |
| 7750 (oct) | → | FE8 (hex) |
Why the built-in functions hit ceilings
Excel gives you a function for each direction — =DEC2HEX(A2), =HEX2DEC(A2), =BIN2DEC(A2), and so on. The catch is the range limits: DEC2BIN only accepts numbers from −512 to 511, and DEC2HEX and DEC2OCT are capped too, so a large value returns #NUM!. And to go between two non-decimal bases — binary to hex, say — you have to nest one function inside another, like =DEC2HEX(BIN2DEC(A2)).
The 1-click way — Tellsheet's Number Base Converter
Select the column and run Number Base Converter. Pick a From base and a To base among binary (2), octal (8), decimal (10), and hexadecimal (16) — any pair, in one step, with no length limit. Choose upper- or lower-case hex letters. Anything that isn't a valid number in the source base is left untouched, so labels and headers in the column are safe. Pairs with Add Leading Zeros and Convert Text to Number.
Frequently asked questions
Why does DEC2BIN fail on big numbers?
It only accepts −512 to 511. The Number Base Converter has no length limit, so long values convert fine.
Can I go binary → hex directly?
Yes — pick any From and To base; you don't have to route through decimal or nest functions.
Upper or lower case hex?
Your choice — there's a toggle for upper-case hex letters (FF vs ff).
What about non-number cells?
They're left exactly as they are; only valid numbers in the source base are converted.
Related Excel guides
Convert number bases in one click
Number Base Converter moves whole columns between binary, octal, decimal, and hex — any pair, no length limit, invalid cells left alone.
Get Tellsheet free See pricing