Number Base Converter

Convert numbers between binary, octal, decimal, and hex.

How to use Number Base Converter

1

Enter your number in the input field

Click the text input box labeled 'Enter Number' and type or paste your number. You can input values up to 32 digits long.

2

Select the source number base

Click the 'From Base' dropdown menu and choose your input format: Binary (Base 2), Octal (Base 8), Decimal (Base 10), or Hexadecimal (Base 16).

3

Choose your target number base

Click the 'To Base' dropdown menu and select the output format you need from the four available base options.

4

View instant conversion results

Your converted number appears automatically in the 'Result' field below. Click the copy icon next to the result to copy it to your clipboard.

Related Tools

Number base converter online: binary, decimal, hex, and octal

Number base converter online: binary, decimal, hex, and octal

Convert numbers between binary (base 2), octal (base 8), decimal (base 10), and hexadecimal (base 16) at ToolHQ's number base converter, enter in any base and all four representations update instantly, free with no account required.

A number base (or radix) is the number of unique digits a numeral system uses to represent values, and the four bases used in computing each serve a different technical purpose.

Developers, students, and system administrators work across these number systems constantly: hex color codes in CSS, binary in logic design, octal in Unix file permissions, and decimal for everyday use. Switching between them manually is error-prone and slow. ToolHQ's converter shows all four simultaneously so you have every representation at a glance.

Key Takeaways

  • Convert between binary (base 2), octal (base 8), decimal (base 10), and hex (base 16) simultaneously
  • Enter a number in any base field and all three other fields update instantly
  • No data is stored or transmitted, all calculations run locally in your browser
  • The quick reference table below covers 0-15 in all three common developer bases
  • Used daily in web development, system programming, networking, and CS education

What is a number base converter and why do these bases matter?

A numeral system is how numbers are represented using digits. The familiar decimal system uses 10 digits (0-9). Computers operate in binary (0 and 1) because electronic circuits have two states: on or off. The other systems evolved as convenient human-readable shortcuts for binary:

  • Binary (base 2): Uses digits 0 and 1. Every number is a combination of these. This is the fundamental language of all digital computation.
  • Octal (base 8): Uses digits 0-7. Each octal digit represents exactly three binary digits, making it a compact representation used in Unix file permissions (e.g., chmod 755 = rwxr-xr-x).
  • Decimal (base 10): Uses digits 0-9. The standard human counting system. Computers output in decimal for human readability.
  • Hexadecimal (base 16): Uses digits 0-9 and letters A-F. Each hex digit represents exactly four binary digits (one nibble). Used extensively in web colors (#FF6600), memory addresses, and machine code.

ToolHQ's converter updates all four representations simultaneously as you type, enter a decimal number and immediately see the binary, octal, and hex equivalents side by side.

All calculations run locally in your browser, no data is stored or transmitted.


When to use a number base converter

You need a number base converter whenever you are working across systems that use different representations:

  • Web development: Converting hex color codes to decimal RGB values and back
  • Unix/Linux administration: Understanding octal file permissions (755, 644, 777)
  • Networking: Converting binary IP addresses and subnet masks to decimal notation
  • Computer science education: Understanding binary arithmetic, bit manipulation, and two's complement
  • Embedded systems and hardware: Working with memory addresses in hex and register values in binary
  • Cryptography: Understanding byte values expressed as hex in hash outputs and encodings

Mini-story 1: Priya was a computer science student working through a bit manipulation exercise. The problem gave her a value in binary and asked her to find its hexadecimal representation, then confirm the decimal value. She had always converted these manually and made arithmetic errors. She typed the binary string into ToolHQ's number base converter and immediately had the hex and decimal values alongside it, the answer she needed and a visual confirmation that her manual work was right. She started using the tool as a verification step for all her base conversion homework.

Convert number bases free at ToolHQ


How to use the ToolHQ number base converter

The tool updates in real time:

  1. Go to the tool. Navigate to ToolHQ's number base converter. No account or sign-up required.
  2. Enter your number. Type a value in any of the four fields: binary, octal, decimal, or hexadecimal.
  3. Read all representations. The other three fields update instantly to show the equivalent value in each base.
  4. Copy any result. Click a field value to copy it to your clipboard for use in code, documentation, or design tools.
  5. Convert again as needed. Clear and enter a new value in any field, there is no limit on how many conversions you run.

For working with hexadecimal in text or code directly, ToolHQ's base64 encoder and hash generator handle adjacent encoding and hashing tasks that often come up alongside base conversion.


Developer quick reference: 0-15 in decimal, binary, and hex

This table covers the most-referenced range for hex and binary work, the single hex digit values:

Decimal Binary Hex Notes
0 0000 0
1 0001 1
2 0010 2
3 0011 3
4 0100 4
5 0101 5
6 0110 6
7 0111 7 Last octal digit
8 1000 8
9 1001 9
10 1010 A
11 1011 B
12 1100 C
13 1101 D
14 1110 E
15 1111 F Single hex digit max

One byte (8 bits) ranges from 00000000 to 11111111 in binary, from 0 to 255 in decimal, and from 00 to FF in hex. A hex color like #FF0000 (pure red) is three bytes: FF (255 red), 00 (0 green), 00 (0 blue).

Mini-story 2: Lars, a back-end developer, was reviewing a network packet capture and needed to decode a series of hex values in a header. He pasted each hex pair into ToolHQ's number base converter to see the decimal equivalent of each byte, then cross-referenced the decimal values against the protocol specification. Having all four representations visible at once meant he could follow the protocol values in decimal while checking the raw hex from the capture, a workflow that would have been painful with two separate tools.


Frequently asked questions

What is the fastest way to convert decimal to binary?

Divide the decimal number by 2 repeatedly, noting the remainder each time, and read remainders bottom to top. For example, 13 → 8+4+1 → 1101. ToolHQ's converter does this instantly.

What does hexadecimal A-F represent?

A = 10, B = 11, C = 12, D = 13, E = 14, F = 15 in decimal. These letters extend hex beyond single digits so that any value 0-15 is represented by a single character.

Why are Unix permissions written in octal (like 755)?

Three digits in octal (0-7) each represent three binary bits: read (4), write (2), execute (1). Octal 7 = binary 111 = read+write+execute. Octal 5 = binary 101 = read+execute only.

Can I convert negative numbers or fractions?

ToolHQ's base converter handles positive integers. For negative values or floating-point numbers, the representation is more complex and depends on the encoding (like IEEE 754 for floating point).

Is the number base converter free?

Yes. ToolHQ's number base converter is completely free, with no account, no sign-up, and no usage limits.


The short version

Binary, octal, decimal, and hexadecimal are four representations of the same underlying values, and switching between them is a constant task in programming, network administration, hardware design, and computer science education. ToolHQ's number base converter shows all four simultaneously: enter in any base and the other three update instantly. It is free, runs locally in your browser with no data stored, and requires no account.

For adjacent developer tools, ToolHQ's base64 encoder encodes and decodes binary data for transmission, the hash generator produces hex-encoded hash values, and the URL encoder/decoder handles percent-encoding. Explore more developer tools at ToolHQ for the full developer toolkit.

Convert number bases free at ToolHQ