← All Tools
Number Base Converter🔒 100% local
Convert between number bases. Privacy-first, no server uploads, no tracking.
Converts an integer from one base to another. You supply "number, fromBase, toBase", it parses the number in the source base, prints the result in the target base, and always also shows the same value in decimal, binary, octal and hex. Both bases may be anything from 2 to 36.
How to use it
- Enter three comma-separated values, for example "255, 10, 16".
- Use digits above 9 as a-z or A-Z; case does not matter on input.
- Press Process. The Result line is printed in uppercase.
Worked example
255, 10, 16becomesInput: 255 (base 10)
Result: FF (base 16)
Common bases:
Decimal: 255
Binary: 11111111
Octal: 377
Hex: FF1010, 2, 16becomesInput: 1010 (base 2)
Result: A (base 16)
Common bases:
Decimal: 10
Binary: 1010
Octal: 12
Hex: AWhen to use it
- Reading a hex colour or a hex socket value back as decimal.
- Checking a bitmask written in binary against its hex form.
- Converting between decimal and a base used by an obscure protocol without reaching for a shell.
What it does not do
- The number is parsed with JavaScript's parseInt, which stops at the first character it cannot read instead of rejecting the input. "12abc, 10, 2" returns 1100 (decimal 12) with no error at all.
- Whole numbers only - there is no fractional-base conversion. Negative values do work, because parseInt accepts a leading minus.
- Digits are only checked as far as parseInt checks them, and parseInt will happily read "8" in base 8 as 8 even though 8 is not an octal digit in strict languages.
- The four Common bases lines always show decimal, binary, octal and hex. A base-36 target appears only on the Result line.