Base Converter
Convert numbers between binary, octal, decimal, hexadecimal and any base from 2 to 36, with the working shown step by step.
Key facts
- Each digit is multiplied by a power of the base: binary 1011 is 1×8 + 0×4 + 1×2 + 1×1 = 11 in decimal.
Decimal uses only the digits 0–9
In binary (base 2)
11111111
Decimal 255 is 1111 1111 in binary (base 2).
128 + 64 + 32 + 16 + 8 + 4 + 2 + 1 = 255
Tap a bit to flip it. Each tile is worth its digit × 2n.
How this works: Method, Checked against 10 worked examples,
How this works
Method
A number in any base from 2 to 36 is read digit by digit as an exact whole number (each digit times a power of the base), then written in the new base by dividing repeatedly and reading the remainders backwards, so even 64-bit values never round. Text goes through its UTF-8 bytes, signed numbers use two’s complement in 8, 16, 32 or 64 bits, floats are encoded exactly to IEEE 754 single or double precision, and Roman numerals use the standard subtractive form from 1 to 3,999.
How it’s tested
10 worked examples for this page are checked by automated tests before every release: given the inputs, the tool must show the expected answer.
Privacy
On your device. Nothing you enter or open leaves this browser. About privacy labels
Changes
- Rebuilt with 18 conversion pages, including text to binary and hex, two’s complement, IEEE 754 floating point, a bitwise calculator and Roman numerals, each with its method and a table.
- Added key facts with worked examples of converting between bases.
- Redesigned: the working shown step by step, and the same number in the other common bases under the answer.
- Fixed large numbers: values above 2^53, such as 64-bit hex, now convert exactly instead of rounding.
- First published.
All 18 conversions
Binary, decimal, hex and octal · Text, ASCII and UTF-8 · Signed numbers, floats and bits · Other number systems
Binary, decimal, hex and octal
Text, ASCII and UTF-8
Signed numbers, floats and bits
Other number systems
Frequently Asked Questions
What is a base converter and how does it work?
A base converter is a tool that transforms numbers from one numeral system to another. It works by converting the input number to decimal (base 10) first, then converting from decimal to the target base using division and remainder operations.
What number bases can I convert between?
Our base converter supports conversions between any base from 2 (binary) to 36. Common bases include binary (base 2), octal (base 8), decimal (base 10), and hexadecimal (base 16). For bases above 10, we use letters A-Z to represent values 10-35.
How do I convert binary to decimal?
To convert binary to decimal, multiply each digit by 2 raised to its position power (starting from 0 on the right), then sum all results. For example, 1011 in binary equals 1×2³ + 0×2² + 1×2¹ + 1×2⁰ = 8 + 0 + 2 + 1 = 11 in decimal.
What is hexadecimal and where is it used?
Hexadecimal (base 16) uses digits 0-9 and letters A-F (representing 10-15). It's widely used in programming, web design (color codes), and computer science because it provides a compact way to represent binary data. Each hex digit represents exactly 4 binary digits.
Can I share my conversion results?
Yes! The page address always holds the number and both bases, so copying it (or using Copy link in the ⋯ menu beside the result) shares the exact conversion. Anyone who opens the link sees the same result and working.
Can it convert text, negative numbers or floats too?
Yes. Pick a converter at the top of the tool: text to binary or hex (and back), two’s complement for signed numbers, IEEE 754 for floating point, a bitwise calculator and Roman numerals. Each has its own page with the method and a table of common values.