devtools

Number Base Converter

Convert between binary, octal, decimal and hex — with big-number support.

client-sidefreeno-signup
binary/2
octal/8
decimal/10
hex/16
converted locally in your browser · BigInt handles arbitrary precision
// how to use

How to use the Number Base Converter

Convert a number between binary, octal, decimal and hexadecimal with all four fields updating live as you type. Because it uses BigInt internally, even very large values convert without the precision loss that affects JavaScript’s regular Number type.

  1. 01Type your value into any one of the four fields — binary, octal, decimal or hex.
  2. 02The other three fields update instantly to match.
  3. 03Copy whichever format you need. Prefixes like 0x, 0b and 0o are optional.

tips

  • JavaScript Numbers lose precision past 2⁵³ − 1; this tool uses BigInt so a 200-bit value is still exact.
  • Negative values are supported — the minus sign is preserved across every base.
  • Hex letters are case-insensitive, so FF and ff mean the same thing.

frequently asked

What number bases are supported?+

Binary (base 2), octal (base 8), decimal (base 10) and hexadecimal (base 16) are the built-in presets. Each field updates the others live as you type. The tool uses BigInt internally, so very large numbers work without losing precision.

Why does JavaScript lose precision on big numbers?+

JavaScript’s Number type is a 64-bit float, which can only represent integers exactly up to 2⁴⁵ - 1 (9,007,199,254,740,991). Beyond that, digits degrade. This tool uses BigInt instead, so a 200-bit binary value converts to hex without any rounding.

Can it handle negative numbers?+

Yes. Enter a leading minus sign in any field and the sign is preserved across all conversions.

Is this tool free?+

Yes. All conversion happens in your browser — nothing is uploaded.

related tools