Contania

Number Base Converter

Computers count in binary; programmers use hexadecimal; we use decimal. Convert a number between binary, octal, decimal and hexadecimal by entering its base.

Your numbers

Result

Binary
11111111
Hexadecimal
FF
Decimal
255
Octal
377
The same number in each base
BaseRepresentation
Binary (base 2)11111111
Octal (base 8)377
Decimal (base 10)255
Hexadecimal (base 16)FF
Advertisement

What number bases are

The base sets how many digits a system uses. Decimal (base 10) uses 0-9; binary (base 2) only 0 and 1; octal (base 8), 0-7; hexadecimal (base 16) runs 0-9 then A-F (A=10 ... F=15). The number 255 in decimal is 11111111 in binary and FF in hex.

Why binary and hex matter

Electronic circuits store information as two states (on/off), which is binary. Because bit strings get long, programmers use hexadecimal, where each digit maps to 4 bits — shorter and easier to read. Web colors (#FF0000) and memory addresses are written in hex.

Frequently asked questions

Sources

  • Positional numeral systems (math / computing)

Related calculators