Developer Tools Runs in your browser Free · no account

Number Base Converter

The number base converter changes whole numbers between any pair of bases from binary through to base 36. It converts a whole list at once, tolerates 0x, 0b and 0o prefixes and digit grouping, and uses arbitrary-precision arithmetic so very large values convert exactly rather than losing precision.

Options
Numbers (one per line) 0 characters
Converted

Your result will appear here.

Not sure where to start? Use Load example.

Results update automatically and are calculated on your device. Nothing you type is sent to a server.

Runs in your browser. Processing happens entirely in your browser. Nothing you enter is sent to Delimiter.live.

How to use the Number Base Converter

  1. Paste one number per line.
  2. Set the base you are converting from and the base you want.
  3. Read the table — each input line is converted independently.
  4. Copy the result.

Example

Input
255
Output
11111111

Common use cases

  • Converting a hexadecimal value from a debugger into decimal.
  • Turning a decimal file permission into octal.
  • Reading a binary mask as decimal to check a flag.
  • Converting an identifier into base 36 to shorten it.

Limitations and things to watch for

  • Whole numbers only. Fractional values and exponent notation are not converted, because representing a fraction in an arbitrary base raises rounding questions with no single right answer.
  • A leading minus sign is preserved, but the tool does not model fixed-width two's complement — it converts magnitudes, so it will not show you the 32-bit representation of a negative number.
  • Bases above 10 use the letters a to z for digits, giving a maximum of base 36.

Frequently asked questions

How is this different from the Text to Binary converter?
That tool converts text into the numeric values of its characters. This one converts numbers between bases — give it 255 in base 10 and it returns 11111111 in base 2. Different job entirely.
Can I paste values with 0x or 0b prefixes?
Yes. Those prefixes are stripped before conversion, as are spaces, underscores and commas used for digit grouping, so you can paste values straight from code or a debugger.
Will very large numbers stay exact?
Yes. Conversion uses arbitrary-precision integers rather than floating point, so a 40-digit value converts exactly. A naive implementation using ordinary numbers would silently lose precision beyond about 16 digits.
Why was my number rejected?
It contains a digit that does not exist in the base you selected — an 8 or 9 in an octal number, for instance. The error names the offending character.

Share this tool