Calculateus

Number Base Converter

Convert numbers between binary, octal, decimal and hexadecimal.

Result

Binary
11111111
Octal
377
Decimal
255
Hexadecimal
FF
86420Digit Count: 8Digit Count: 3Digit Count: 3Digit Count: 2BinaryOctalDecimalHex

About the Base Converter

Numbers can be represented in different bases - binary, octal, decimal, and hexadecimal are the most common in computing - and converting between them is essential for programming and computer science work. Our Number Base Converter handles all four at once.

How It Works

The calculator parses your input value according to your selected source base, then converts that underlying numeric value into each target base's representation - binary (base 2), octal (base 8), decimal (base 10), and hexadecimal (base 16).

Formula & Methodology

Every positional number system works the same way: each digit's place represents a power of the base, and the digit's value multiplies that place value. Decimal (base 10) uses places worth 1, 10, 100, and so on; binary (base 2) uses places worth 1, 2, 4, 8; hexadecimal (base 16) uses places worth 1, 16, 256, extending its digit set with A through F to represent values 10 through 15 in a single character. Converting between bases means re-expressing the same underlying quantity using a different set of place values.

Step-by-Step: Calculating It By Hand

  1. 1Select the source base matching how your input number is written.
  2. 2Enter the value using digits valid for that base.
  3. 3The calculator interprets the value's true numeric quantity based on the source base's place values.
  4. 4It then re-expresses that same quantity in each target base's digit system.

Examples

Decimal to other bases

The decimal number 255 converts to 11111111 in binary, 377 in octal, and FF in hexadecimal - all representing the exact same underlying quantity.

Binary to decimal

The binary number 1010 (entered with binary as the source base) converts to 10 in decimal - a common conversion in programming and computer science contexts.

Advantages

  • Converts to all four common bases at once, not just one target base
  • Handles binary, octal, decimal, and hexadecimal - the bases most relevant to computing
  • Validates input against the selected source base, catching invalid entries
  • Fast, essential tool for programming and computer science work

Common Mistakes

  • Entering digits invalid for the selected base (like using '8' or '9' in an octal number)
  • Confusing hexadecimal's letter digits (A-F representing 10-15) with decimal digits
  • Not selecting the correct source base before entering a value
  • Assuming a number 'looks like' a certain base just from its digits, without explicitly specifying the source base

Edge Cases to Watch For

  • Entering a digit invalid for the selected base (like an '8' while in octal mode, which only uses digits 0-7) produces an invalid input.
  • Hexadecimal uses letters A through F to represent values 10 through 15, which can be visually confused with decimal digits if the base isn't clearly tracked.
  • Very large numbers can produce long strings of digits in binary specifically, since it has only two possible digit values per place.
  • Leading zeros don't change a number's value in any base, though they're sometimes used conventionally to indicate a fixed bit-width in programming contexts.

Common Use Cases

  • Programming and computer science coursework involving number base conversions
  • Converting between binary, hex, and decimal for low-level programming work
  • Computer science education and understanding number representation
  • Quick verification of manually converted base representations
Written & fact-checked by the Calculateus TeamLast updated August 5, 2026How we verify our formulas

Frequently asked questions

Why does hexadecimal use letters?

Hex is base 16, but our number system only has 10 digits (0-9), so hex borrows A-F to represent values 10-15 in a single digit - that's why FF equals 255 in decimal.

Conclusion

Number base conversion is a foundational computer science skill, and having all four common bases converted at once saves repeated lookups. This handles the most common bases used across programming and digital systems work.