m.MomentHow bases work

A DIFFERENT WAY TO COUNT

Same number.
A different base.

Move between binary, decimal, hexadecimal, and every base in between. Keep the whole value, however long it gets.

Number base converter

Exact integer conversion

Up to 1,024 digits, with an optional plus (+) or minus (-) sign. Use plain digits and letters, without prefixes such as 0x or 0b.

Enter an integer to begin.

ONE VALUE, MANY REPRESENTATIONS

The place makes the difference.

Count with a different alphabet

Decimal uses ten digits, 0–9. Binary uses just 0 and 1. Hexadecimal adds A–F to represent values ten through fifteen.

Look at each position

In base 16, the rightmost position counts ones and the next counts sixteens. So FF means 15 × 16 + 15, which is 255 in decimal.

Keep the value exact

Large integers are calculated without floating-point rounding. For example, decimal 9007199254740993 becomes hexadecimal 20000000000001.

A few useful details.

Which inputs are accepted?

Enter a whole number using digits 0–9 and letters A–Z as allowed by your chosen source base. Lowercase letters work too. A single ASCII plus (+) or minus (-) may appear at the start. Outer whitespace is removed; separators, internal spaces, decimal points, and other signs are not accepted.

How are prefixes and leading zeros handled?

Prefixes are never detected or removed. Enter FF with source base 16, rather than 0xFF. In a high enough base, the letters in 0x or 0b can themselves be valid digits and are interpreted literally. Leading zeros do not change the value; results omit them. Negative zero becomes 0.

Can I convert fractions or two’s complement?

This converter handles signed integers only. A negative result keeps a minus sign, such as -FF. It does not interpret a fixed bit width, two’s complement, byte order, fractions, or exponent notation. In bases where E is a valid digit, E is treated as a digit, not an exponent marker.

How long can a result be?

Each input can contain up to 1,024 digits, excluding its sign. A result can be longer because different bases use different numbers of digits. All letters in results use uppercase.

Does this send or save my numbers?

Conversion runs in this browser tab. This tool does not upload numbers, save inputs, use analytics, or display advertising. Reloading clears your work. The hosting provider may process ordinary connection logs.