Developer tool

Number Base Converter

Convert integers exactly between bases 2–36, even beyond the safe integer range.

Continue your work

Choose a related tool for the next step. Each opens with a fresh workspace.

Practical guide

How to use Number Base Converter

Convert integer identifiers, bit masks, hexadecimal values, and binary examples without passing through floating-point arithmetic. Select any source and destination bases from 2 through 36. The input stays visible beside an exact, copyable result, including when the value is larger than the safe integer range of a JavaScript Number.

Step by step

  1. Enter the integer and select its source base. A matching 0b, 0o, or 0x prefix is optional for binary, octal, or hexadecimal.
  2. Choose the destination base and select Convert. Invalid digits are rejected instead of silently truncated.
  3. Copy the result or select Swap bases to convert a successful result back to its original base.

Example

Input9007199254740993 (base 10)
Result20000000000001 (base 16)

How it works

Each digit is checked against the selected alphabet and accumulated using BigInt multiplication and addition. Output uses digits 0–9 followed by lowercase letters a–z. Leading zeroes and a positive sign are normalized away; a negative value keeps a leading minus sign.

Important limitations

  • Only whole integers are supported. Decimal fractions, exponent notation, digit separators, and internal whitespace are rejected.
  • Negative values use signed magnitude text, not a fixed-width two’s complement representation. Input is limited to 4,096 digits.

Real workflows

When this tool is useful

Database identifiers

Translate a large decimal identifier into hexadecimal for a diagnostic report without losing low-order digits.

Protocol inspection

Read a binary mask as a decimal or hexadecimal integer before checking individual bit positions in your protocol documentation.

Review the result

What to check before using the output

Confirm the source base first: the same digits can mean very different values in different bases. Round-trip the result with Swap bases when accuracy matters, and compare its normalized value with the original.

  • Select the correct source alphabet.
  • Keep the original digit string.
  • Check whether a fixed width is required.

Choose the right method

When another tool is better

Use a programmer calculator or a language library when fixed-width signed integers, bitwise operations, byte order, fractions, or overflow behavior are part of the question.

Privacy and browser behavior

Conversion runs in memory in the active tab. Integer identifiers can still identify users or internal records, so avoid including real account identifiers in public screenshots.

Frequently asked questions

Can I convert a 64-bit database ID?

Yes. Paste the original digit string directly. Do not first parse it as a JavaScript Number, because any precision already lost cannot be recovered by this tool.

Why did leading zeroes disappear?

The result represents a number rather than a fixed-width code. Add padding separately if a protocol requires a particular width; do not use this tool to preserve identifier formatting.