Skip to content

Number Base Converter

Convert between binary, octal, decimal and hexadecimal, including values too large for a JavaScript number.

Enter something above to see the result.

Converting between bases

Enter a value and pick the base it is written in; every other representation appears at once. Prefixes are understood, so 0xff, 0b1010 and 0o777 can be pasted as-is.

Conversion uses arbitrary-precision integers, so values beyond 2⁵³ — where a JavaScript number silently loses accuracy — convert exactly.

Frequently asked questions

Can I convert very large numbers?

Yes. BigInt arithmetic is used throughout, so a 40-digit hexadecimal value converts without losing a single digit.

What is the 32-bit binary row for?

It zero-pads the value to 32 bits, which is the form you want when reading register values, bit flags or permission masks.

Related tools