W3docs

Tools

Number Base Converter

Convert a number between any two bases from 2 (binary) to 36. Common bases — binary, octal, decimal, hexadecimal — are labeled for convenience.

How it works

  1. Enter your number — integers only. A leading - is accepted for negatives.
  2. Pick the source base.If the input contains a digit that isn't valid for that base, an inline error appears.
  3. Pick the destination base — anywhere from 2 to 36.
  4. Done. The result updates as you type; click Swap to flip from/to with the current result as the new input.