Skip to content

Number Base Converter

Convert a number between binary, octal, decimal and hexadecimal, all at once.

Runs in your browserFree, no sign-up

Settings

Results update automatically as you type.

Binary
11111111
Octal
377
Decimal
255
Hexadecimal
FF

About the Number Base Converter

This number base converter takes a number in any of binary, octal, decimal or hexadecimal and instantly shows its equivalent in all four bases at once, rather than making you run separate conversions each way. It's built for programmers checking a byte value, students working through a computer science course, or anyone converting a color code or memory address between bases.

How to use the Number Base Converter

  1. 1

    Type the number you want to convert.

  2. 2

    Choose which base it's currently written in — binary, octal, decimal or hexadecimal.

  3. 3

    Read the equivalent value in all four bases at once.

What people use it for

Checking a hex color or byte value

Convert a hexadecimal value like FF to decimal (255) to understand exactly what a color channel or byte setting represents.

Working through computer science coursework

Verify manual binary-to-decimal or decimal-to-hex conversions while learning number systems, without reaching for a scientific calculator.

Debugging low-level code

Quickly translate a binary flag or octal file permission value (like chmod's 755) into decimal or hex for a debugger or log message.

How positional number systems work

Every number system here is positional: each digit's value depends on its position, multiplied by a power of the base. In decimal (base 10), the digits in '255' represent 2×100 + 5×10 + 5×1. Binary (base 2) uses only 0 and 1, with each position worth a power of two; hexadecimal (base 16) uses 0-9 then A-F to represent 10-15 in a single digit, which is why FF equals 255 — each F is 15, and 15×16 + 15 = 255.

Tips

  • Hexadecimal is shown uppercase by convention, but lowercase hex is equally valid — most programming languages accept either.
  • The largest value this tool converts precisely is 9,007,199,254,740,991, the largest integer JavaScript can represent exactly without rounding.
  • Octal (base 8) is less common today but still shows up in Unix file permissions, where each digit represents read/write/execute bits.

Frequently asked questions

What is the largest number this tool can convert?
Up to 9,007,199,254,740,991 (Number.MAX_SAFE_INTEGER) — the largest integer JavaScript can represent exactly. Larger values are rejected rather than silently rounded.
Does it handle negative numbers?
No — binary, octal and hex are positional systems defined for non-negative integers here. For a signed value, convert its absolute value and note the sign separately.
Why is hexadecimal shown in uppercase?
Both cases are valid hex; uppercase (FF rather than ff) is the more common convention in color codes, memory addresses and most documentation, so that's what's shown. Lowercase works fine as input either way.

Looking for something else? Browse all developer tools or see every tool.