Maths & numbers

Integer base converter

Convert a signed whole number between numeral bases 2 through 36 without floating-point rounding.

Your numbers

Digits 0–9 and A–Z, optionally prefixed by minus. No decimal point.

Calculated on your device. Your inputs aren’t sent to us.

Your result

Ready when you are

Enter your inputs and select Calculate.

Report an issue

Try it, understand it

Explore the result

Compare these worked scenarios while keeping the units and assumptions visible.

Worked example comparison
ExampleOutputWhat to notice
Four standard numeral representationsValue in base 211111111FF hexadecimal is decimal 255 and binary 11111111.
A signed integerValue in base 16-2AThe minus sign applies to the whole magnitude.
Leading zeroesValue in base 105They do not establish a fixed bit width.

Check your understanding

Can I see binary octal decimal and hexadecimal together?

Yes. All four are included alongside the selected destination output.

Does a leading zero establish a byte width?

No. This is mathematical signed-integer conversion, not a fixed-width encoding.

Behind the numbers

How this calculation works

Each source digit contributes its value times a power of the source base. Repeated division by the destination base supplies output digits from right to left. Letters A through Z stand for digit values 10 through 35.

THE FORMULAValue = Σ digit × base^position; rewrite that exact integer in the destination base

A worked example

FF in base 16 is 255 in base 10 and 11111111 in base 2. The sign, if present, is applied to the whole number.

Good to know

Whole numbers only, with at most 64 source digits. No fractional portion, bit width, two’s-complement interpretation or preservation of leading zeros. Invalid digits for the selected source base are rejected.

A numeral is a weighted list of digits

The chmod permission calculator interprets octal mode bits and a separate umask creation example. A numeric base conversion alone does not explain file access flags. Hexadecimal FF has two F digits, each worth 15. The right one contributes 15×16⁰ and the left one contributes 15×16¹, so the value is 255. In binary, the same whole number is 11111111. The quantity stays the same while its written representation changes.

The table shows input place values. For long inputs it displays only the rightmost twelve places to keep the page readable; the conversion still uses every entered digit.

The modular exponentiation calculator works with an integer value after its numeral base has been interpreted.

Choose the alphabet before interpreting letters

The source base controls which digits are legal. In base 12, B means eleven and C is invalid. In base 16, F means fifteen. The output uses uppercase A–Z for values ten through thirty-five.

A data size converter changes physical byte units such as MB and MiB. This page changes numeral notation only: base 2 is not a byte unit, and a hex value does not say how many bits or bytes a file occupies without an encoding.

Signed value is not a machine bit pattern

A leading minus sign describes a negative mathematical integer. It is not a two’s-complement encoding, a fixed-width register, or an interpretation of a signed byte. Leading zeros are not preserved because they do not change the integer.

The modular exponentiation calculator uses the integer value in a remainder calculation after you know what the numeral means. This converter itself performs no modular reduction.

A numeral is a representation of one integer

The original four-base page represented decimal, binary, octal and hexadecimal simultaneously. The recovered tool keeps those four representations in the result while retaining arbitrary source and destination bases from two through thirty-six. Changing base changes the written digits, not the underlying signed whole-number value.

The fraction to decimal converter addresses rational fractions, which are a separate representation problem. This base converter deliberately supports whole numbers only. It does not silently truncate a fractional numeral or interpret the leading bits of a negative value as a fixed-width machine word.

Leading zeros and machine encodings need a separate convention

A leading zero does not change the mathematical integer, so it is not retained as an implied bit width. A minus sign applies to the whole magnitude. Two’s-complement representation would require an explicit width and another interpretation, neither of which should be guessed from the entered digits.

The large integer is processed with BigInt rather than first passing through a floating-point Number. Invalid source digits are rejected before conversion. The prime factorization calculator likewise works with integer structure, but converting a numeral base does not reveal factors or change primality.

A few questions, answered

Can I enter lowercase hexadecimal?

Yes. Letters are normalized to uppercase before digit validation.

What does base 36 add?

Digits 0–9 followed by letters A–Z, with Z worth 35.

Does this convert fractions?

No. Only whole-number numerals, with an optional minus sign, are supported.

Can I see binary octal decimal and hexadecimal together?

Yes. All four are included alongside the selected destination output.

Does a leading zero establish a byte width?

No. This is mathematical signed-integer conversion, not a fixed-width encoding.

Find your calculator

Start typing to explore the library.