Number Base Converter
See exact whole-number equivalents in binary, decimal, hex and octal.
Enter a whole number and choose the base it uses.
Example · 255 across number bases
Binary
11111111
255 in decimal is 11111111 in binary.
Hexadecimal
FF
Octal
377
Conversion steps
255 ÷ 2 = 127, remainder 1 127 ÷ 2 = 63, remainder 1 63 ÷ 2 = 31, remainder 1 31 ÷ 2 = 15, remainder 1 15 ÷ 2 = 7, remainder 1 7 ÷ 2 = 3, remainder 1 3 ÷ 2 = 1, remainder 1 1 ÷ 2 = 0, remainder 1 Read the remainders from last to first.
The caret marks a power. For example, 2^3 means 2 × 2 × 2.
Processed on this device — nothing is uploaded
What you can do here
- Binary, decimal, hex and octal
- Exact conversions with BigInt
- Negative whole number support
- Place-value steps for decimal
- Copy each converted value
What does a number base converter do?
A number base converter writes the same whole number using different digit systems. Decimal 255 is binary 11111111, hexadecimal FF and octal 377. Choose the source base and type a number to see all three other representations. The converter uses exact integer arithmetic for up to 256 input digits and accepts negative values.
The place-value steps show how to reach the decimal equivalent. For example, hexadecimal FF is 15 × 16 + 15, which equals decimal 255.
Key facts
- Price
- Free
- Sign-up
- None
- Upload
- None — runs on your device
- Limits
- Up to 256 input digits · Whole numbers, including zero and negatives
- Works with
- Binary, decimal, hexadecimal or octal integers · Optional 0b, 0x or 0o prefix in the matching base
- Output
- Exact equivalents in the three other bases · Decimal place-value steps
- Updated
How do you convert a number to another base?
- Choose the input base
Select Binary, Decimal, Hexadecimal or Octal.
- Enter a whole number
Type the number with digits allowed in that base. Add a leading minus sign for a negative number.
- Read its equivalents
Copy a converted value or read the place-value steps to check the decimal equivalent.
Which digits are used in each number base?
Work from the right. Multiply each digit by its base raised to the power of its position, starting with zero, and add the terms to get the decimal value.
| Base | Allowed digits | Decimal 255 |
|---|---|---|
| Binary (2) | 0–1 | 11111111 |
| Decimal (10) | 0–9 | 255 |
| Hexadecimal (16) | 0–9 and A–F | FF |
| Octal (8) | 0–7 | 377 |
Frequently asked questions
What is decimal 255 in binary, hex and octal?
It is 11111111 in binary, FF in hexadecimal and 377 in octal.
Can I enter a number larger than 2 to the power of 53?
Yes. BigInt keeps conversions exact up to the input limit of 256 digits.
Can I convert negative numbers?
Yes. Type a minus sign before the digits. The output uses a leading minus sign in every base.
Can I enter prefixes such as 0b, 0x or 0o?
Yes. Use 0b in Binary, 0x in Hexadecimal or 0o in Octal. Choose the input base before typing a prefixed number.
Does the converter handle fractions?
Enter a whole number such as 255 or -14. This converter accepts integers.
Popular conversions
Related tools
About this tool
Made by ZirkoMirko. Last updated .
Check it yourself in your browser’s Network panel while using the tool. How we handle your data.