Calculators & Converters

Number Base Converter

Convert large integers between positional number systems without losing digits to floating-point rounding. Choose any input and output base from 2 through 36, and compare the four common programmer formats.

Free online tool

Loading tool…

Convert an integer between bases

Use up to 1,000 digits. A–Z represent values 10–35. Uppercase and lowercase are accepted; omit 0x, 0b, spaces, and separators.

Results

Base 10 result
255
Common number bases
BaseRepresentation
Decimal (10)255
Binary (2)11111111
Octal (8)377
Hexadecimal (16)FF

Magnitude bit length: 8. Signed values use a minus sign, not a fixed-width two’s complement encoding. Zero is represented by one binary digit.

Calculations and exports run locally in your browser. Your entries are not sent to a calculation service.

GET STARTED

How to use the Number Base Converter

  1. 01

    Enter an integer without prefixes, commas, or spaces, then choose its source base.

  2. 02

    Choose the destination base and check the common-base table.

  3. 03

    Use the result-and-reverse button to convert back, or copy and download the full conversion.

Examples

Hexadecimal to decimal

FF in base 16 is 15 × 16 + 15 = 255 in decimal. Its binary representation is 11111111.

A binary place value

101101 in base 2 represents 32 + 8 + 4 + 1 = 45 in decimal, or 2D in hexadecimal.

Beyond ordinary safe integers

9007199254740993 remains exact when converted because the parser accumulates a BigInt. It is not first rounded into a JavaScript Number.

Read digits by place value

Each position contributes its digit value multiplied by a power of the base. The rightmost position has power zero. In base 16, letters A through F represent digit values 10 through 15; bases up to 36 extend that alphabet through Z.

Validate against the selected base

A digit must be smaller than the base. The input 102 is therefore invalid in binary even though it looks like a valid decimal integer. Uppercase and lowercase letters are accepted, and output letters are uppercase.

Signed integers are not bit patterns

A negative value is shown with a leading minus sign. The tool does not choose a fixed width, infer endianness, or generate two’s complement encodings. Magnitude bit length describes the absolute value’s binary digit count, with one digit used for zero.

What to know

  • Integer conversion only, using bases 2–36 and a maximum of 1,000 input digits.
  • No automatic radix prefixes, fixed-width machine encodings, separators, or fractional expansion.

Common questions

Should I include 0x or 0b?

No. Choose the base in the selector and enter only the signed digits. Prefixes are not automatically recognized; their letters can be ordinary digits in larger bases.

Can I convert a fraction such as 0.1?

No. This converter handles integers only. Fractional base expansions need additional precision and rounding choices that are outside this workflow.

Is there a maximum integer size?

The input is limited to 1,000 digits to keep parsing and rendering responsive. The output may contain more digits when converting to a smaller base.

Sources & references