Decimal to Binary Converter

The Decimal to Binary Converter takes a plain base-10 number and works out its binary representation for you. Type your value into the Decimal Input field, click Convert, and your binary string shows up in Binary Output — handy the next time you need to check a bit pattern by hand. Use the text to hex converter to translate a string of text into hex values without writing any conversion code yourself.

Understanding the Decimal to Binary Converter: Two Number Systems Side by Side

What Is the Decimal Numeral System?

The decimal numeral system, also called base-10, is the everyday number system built from ten digits: 0 through 9. Each digit's position carries a specific weight determined by a power of 10, so the value of a decimal number depends on both the digit and where it sits. For example:

2345 = (2 × 103) + (3 × 102) + (4 × 101) + (5 × 100)

This positional system is the foundation of everyday arithmetic — and it's exactly what a decimal to binary converter has to unpack before it can produce a binary result.

How the Binary Numeral System Works

The binary numeral system (base 2) is the native language of digital hardware. It uses just two symbols, 0 and 1 — each binary digit (bit) is effectively a switch that's either off (0) or on (1). Just like decimal, each position in a binary number carries a weight, but here it's a power of 2:

For example, the binary number 11012:
$$ (1 \times 2^3) + (1 \times 2^2) + (0 \times 2^1) + (1 \times 2^0) = 8 + 4 + 0 + 1 = 13_{10} $$
  • Each binary digit increases in significance from right to left.
  • The rightmost bit represents \(2^0\), the "ones" place.
  • Binary is the shared language every digital system ultimately speaks, from a microcontroller register to a 64-bit server CPU.
Infographic showing how to convert decimal 108 to binary: repeatedly divide by 2 and record the remainders, then read the remainders bottom-up to get 1101100
Decimal to Binary Converter: 108 = 1101100

Manual Decimal to Binary Conversion: The Division-by-Two Method

Step-by-Step: Converting a Whole Decimal Number

To convert decimal to binary by hand, repeated division by 2 is the standard technique — every remainder becomes the next binary digit. Here's the process:

  1. Divide the decimal number by 2.
  2. Write down the remainder — it will be a 0 or 1.
  3. Replace the number with the quotient from that division.
  4. Repeat until the quotient reaches zero.
  5. Read the remainders in reverse order (last to first) to get the binary result.
while N > 0:
    remainder = N % 2
    N = N // 2
    append remainder to result
# reverse the collected remainders for the final answer

Worked Examples: Decimal to Binary Conversion Step by Step

Example 1: Converting Decimal 10 to Binary

Decimal to Binary Conversion Steps (10 → 1010)
DecimalDivisorQuotientRemainder
10250
5221
2210
1201

Reading the remainder column from bottom to top gives 1010. So, 1010 = 10102.

# Python
print(bin(10).replace('0b',''))  # Output: 1010

Example 2: Converting Decimal 25 to Binary

Decimal to Binary Steps (25 → 11001)
DecimalDivisorQuotientRemainder
252121
12260
6230
3211
1201

Reading the remainders bottom to top gives 11001. So, 2510 = 110012.

// Java
Integer.toBinaryString(25); // Output: 11001

Example 3: A Very Large Decimal Number

Because this converter uses arbitrary-precision arithmetic (JavaScript BigInt) rather than a fixed 32-bit or 64-bit integer type, it doesn't fall over on large decimal input. A number like 9007199254740993 — one past the largest integer a standard JavaScript Number can represent exactly — still converts correctly:

9007199254740993 → 100000000000000000000000000000000000000000000000000001

This matters for anyone checking values that exceed the range of a typical 32-bit or 64-bit calculator, without needing to split the number into chunks manually.

Decimal to Binary Conversion Table & Reference for Common Values

Common Values Conversion Table

An at-a-glance conversion chart is useful for comparing decimal, binary, and hex results side by side. Here's a reference for decimal values 0 through 25, plus a few round numbers:

Decimal / Binary / Hex Conversion Table
DecimalBinaryHex
000
111
2102
3113
41004
51015
61106
71117
810008
910019
101010A
111011B
121100C
131101D
141110E
151111F
161000010
171000111
201010014
251100119
3210000020
100110010064
256100000000100

This table is handy for quickly checking small integer values without running the converter — especially useful in networking, hardware register, and computer science coursework contexts where the same few small numbers come up repeatedly.

Standard Word Sizes for Reference

  • 8-bit: represents decimal 0–255.
  • 32-bit: represents decimal 0–4,294,967,295 (unsigned).
  • 64-bit: represents decimal 0–18,446,744,073,709,551,615 (unsigned).

The converter itself isn't limited to any of these widths — because it uses BigInt arithmetic, it will keep producing a correct binary string well past 64-bit range, which is where a typical hardware calculator or 32/64-bit programming type would overflow.

Using the Decimal to Binary Converter: Input Format and Batch Conversion

What Counts as Valid Input

Type or paste a whole decimal number — digits 0 through 9 only — into the Decimal Input field. Spaces between digits are ignored automatically, so pasting a number copied with grouping spaces (like 1 000 000) still works. Any character outside 0–9 triggers a clear error message telling you exactly which line is invalid, rather than silently producing a wrong result.

Converting Multiple Values at Once

To convert more than one decimal number in a single pass, put each value on its own line in the input box — every line converts independently, in order, and the matching binary results appear in the same order in the Binary Output box. This is useful for checking a whole list of register values or homework answers at once instead of one at a time.

Why Arbitrary-Precision Matters

Many online decimal-to-binary calculators quietly cap out at 32-bit or 64-bit integer ranges, silently producing wrong output — or an error — for anything larger. Because this converter uses JavaScript's BigInt type internally, it isn't limited that way: you can convert decimal values with dozens of digits and still get a correct binary string, which matters for cryptography-adjacent coursework, large counters, and anyone verifying values that a pocket calculator can't hold.

Whether you're teaching binary place value, checking a homework answer, or converting a batch of decimal values from a data dump, this decimal to binary converter gives you an instant, accurate result for whole numbers of any size — no manual division required.