Skip to main content

Number Base Converter

Convert from
Base 10 — digits 0–9
All bases — click a row to set as input, or copy a value
Binary
0b11111111
Octal
0o377
Decimal
255← input
Hexadecimal
0xFF
Bit breakdown8 bits set across 8
1
1
1
1
F
1
1
1
1
F
Tip: Each hex digit maps to exactly 4 binary bits, which is why hexadecimal is the standard compact representation for binary data, memory addresses, and color values. Octal digits map to 3 bits each, and are still used in Unix file permissions like chmod 755.

4 min readUpdated

About Number Base Converter

Convert any whole number between binary (base 2), octal (base 8), decimal (base 10), and hexadecimal (base 16) instantly. Type a value in any one base and see the equivalent in all four bases update immediately, along with a visual bit breakdown showing exactly which binary digits are set.

Number base conversion is a core skill in computer science and programming. Binary is how computers represent data at the hardware level, hexadecimal is the standard for memory addresses, color codes, and byte values, and octal still appears in Unix file permissions (like chmod 755) and some legacy systems. Decimal is how humans normally read and write numbers.

This tool supports custom bases too, so you can convert into or out of any base from 2 to 36 — useful for working with base36 short URLs, custom encoding schemes, or computer science coursework.

Click any result to instantly set it as the new input value, copy any result with one click, and use the bit-by-bit breakdown to understand exactly how a number is represented at the binary level — handy for learning bitwise operations, flags, and masks.

Everything runs locally in your browser using standard JavaScript number parsing. Your numbers are never uploaded or transmitted anywhere.

Number Base Converter Features

  • Runs entirely in your browser

    Number Base Converter processes everything client-side — nothing you paste, type, or upload is sent to a server.

  • Free, instant, no sign-up

    No account, no usage limits, no paywall. Results update as you type or click.

  • Switch between binary, octal, decimal, and hexadecimal in real time

    Convert any whole number between binary (base 2), octal (base 8), decimal (base 10), and hexadecimal (base 16) instantly. Type a value in any one base and see the equivalent in all four bases update immediately, along with a visual bit breakdown showing exactly which binary digits are set.

How to Use Number Base Converter

  1. Type a number into the input field.

  2. Choose which base that number is currently in: binary, octal, decimal, hexadecimal, or any custom base from 2–36.

  3. See the equivalent value in every other base update instantly, along with a bit-by-bit binary breakdown.

  4. Click any result row to use it as the new input, or copy any value with one click.

Examples

Example — Decimal to all bases
Input
255 (decimal)
Output
11111111 (binary) · 377 (octal) · FF (hex)
Example — Hex to decimal
Input
1A2B (hex)
Output
6699 (decimal)
Example — Binary to decimal
Input
101101 (binary)
Output
45 (decimal)
Example — Decode a Unix permission number
Input
755 (octal)
Output
111101101 (binary) · 493 (decimal) · 1ED (hex)
Example — Convert a hex memory address
Input
1A2B (hex)
Output
6699 (decimal) · 15053 (octal)

Practical Uses for Number Base Converter

  • Convert a hex color code's components to decimal for a calculation
  • Understand a Unix file permission number like chmod 755 in binary
  • Convert a memory address from hex to decimal for debugging
  • Convert a binary flag value to decimal to understand a bitmask
  • Check what a base36 short URL code represents in decimal
  • Practice base conversion for a computer science exam

Who Uses the Number Base Converter Tool

  • Computer science students practice converting between binary, octal, decimal, and hex for coursework and exams.
  • Developers convert memory addresses, bitmasks, and flag values between number bases while debugging.
  • System administrators understand Unix file permission numbers like chmod 755 in their binary form.
  • Web developers decode base36 short URL codes or generate compact ID encodings.
  • Electronics and embedded engineers convert register values and hardware flags between hex and binary.

Comparisons

Hexadecimal vs Binary for Representing Data

Binary is the literal, ground-truth representation of how computers store data — every value is ultimately a sequence of 0s and 1s at the hardware level. But binary numbers get long fast: a single byte needs 8 digits, making them tedious to read and compare by eye.

Hexadecimal compresses that same information 4x, since each hex digit represents exactly 4 binary bits, making it the practical choice whenever humans need to read or write binary data — memory addresses, color codes, and hash outputs are all conventionally shown in hex.

Frequently Asked Questions

What number bases are supported?

Binary (base 2), octal (base 8), decimal (base 10), and hexadecimal (base 16) are shown by default, plus a custom base selector supporting any base from 2 to 36.

Can I convert negative numbers?

Yes — enter a negative decimal number (e.g. -42) and it converts correctly across all bases. Binary, octal, and hex results show the negative sign rather than two's complement representation.

Does this support decimal (fractional) values?

This tool converts whole integers only. Fractional values are truncated to the integer part, since binary/octal/hex representations of fractions aren't a single standard format.

What's the largest number this can convert?

Values are handled as standard JavaScript numbers, which are precise up to 2^53 (about 9 quadrillion) before precision is lost. That covers the vast majority of programming and computer science use cases.

How does hexadecimal relate to binary?

Each hexadecimal digit represents exactly 4 binary bits, since 16 = 2^4. That's why hex is commonly used as a compact, human-readable shorthand for binary data — for example, the byte 11110000 in binary is simply F0 in hex.

Why is octal still used today?

Octal remains common in Unix and Linux file permissions. A permission like 755 (rwxr-xr-x) is an octal number where each digit represents 3 bits — read, write, and execute — for owner, group, and others.

Can I use this for base36 or custom bases?

Yes — select 'Custom' and enter any base from 2 to 36. Base 36 uses digits 0-9 and letters a-z, and is commonly used for compact ID encoding and short URLs.

How do I understand a Unix permission number like 755?

Enter 755 with Octal selected as the source base — the binary breakdown shows exactly which read/write/execute bits are set for the owner, group, and others, corresponding to rwxr-xr-x.

Can I convert a hex memory address to decimal?

Yes — enter the hex value (without the 0x prefix) with hexadecimal selected as the source base, and the decimal equivalent appears instantly alongside binary and octal.

What is a base36 encoding used for?

Base36 uses digits 0-9 and letters a-z, giving 36 possible symbols per digit, which makes it useful for compact encodings like short URL codes and generated IDs.

Ready to use Number Base Converter?

It's free, runs entirely in your browser, and there's nothing to install or sign up for.

Scroll up & try it now ↑