Skip to main content

Number Base Converter

Convert an integer from one number base to another in your browser — pick a source base and a target base from 2 to 36, with one-click presets for binary, octal, decimal, and hexadecimal.

Integers only (zero, positive, negative). Values use arbitrary-precision integers, so digits beyond 2^53 are kept exactly. Leading zeros are not preserved and output digits are uppercase. Standard 0b / 0o / 0x prefixes are accepted only when they match the source base.

Processed locally in your browser

How to use it

  1. Enter the integer to convert (for example 255, -FF, or 0b1010)
  2. Choose the source base and the target base, from 2 to 36 or a preset
  3. Click Convert to get the uppercase result in the target base
  4. Copy the result, use Swap to reverse the two bases, or Clear to start over

Values are handled as arbitrary-precision integers with BigInt, so digits far beyond 2^53 stay exact and every conversion round-trips without loss. Negative integers are supported and written with a leading minus sign; a leading plus is accepted for symmetry. Digits are checked against the source base before conversion, so an 8 in octal or a G in hexadecimal is reported rather than silently accepted, and input is case-insensitive while the result is uppercase. Standard 0b, 0o, and 0x prefixes are accepted only when they match the base you selected — a mismatched prefix is rejected, never auto-detected. Leading zeros are not preserved, and this tool converts integers only: decimal fractions, scientific notation, and thousands separators are refused. Everything runs locally in your browser, so the number you enter is never uploaded or stored. This is different from a Base64 Encoder, which encodes bytes or text, and from a Hex Viewer, which lists the raw bytes of a file rather than converting a numeral.

FAQ

We use cookies to run this site and, with your consent, to understand usage and personalize ads. You can change your choice at any time.