Decimal to Binary Converter
The decimal to binary converter divides by 2 again and again and reads the remainders from last to first: 10 in decimal is 1010 in binary. It also converts the part after the point, so 10.625 = 1010.101.
Sources: Wikipedia Updated
Convert decimal numbers (including fractions) to binary, octal, or hexadecimal with step-by-step explanation.
Converted result
How to convert decimal to binary
The whole-number part is converted by repeated division by 2. Take 10.
- Divide by 2 and note the remainder: 10 ÷ 2 = 5 remainder 0.
- Divide the quotient again: 5 ÷ 2 = 2 remainder 1, then 2 ÷ 2 = 1 remainder 0, then 1 ÷ 2 = 0 remainder 1.
- Stop at a quotient of 0 and read the remainders from the bottom up: 1010.
To check, the binary to decimal converter adds the place values back: 8 + 0 + 2 + 0 = 10.
Converting the part after the point: 0.625
The fraction is converted separately by repeated multiplication by 2. Each time, the whole-number part of the result is the next binary digit.
0.625 × 2 = 1.25 → digit 1, carry 0.25 0.25 × 2 = 0.5 → digit 0, carry 0.5 0.5 × 2 = 1.0 → digit 1, carry 0 (stop)
That gives .101, and 0.625 converts exactly because 0.625 = 5/8 and 8 is a power of 2. Joined to the whole part: 10.625 = 1010.101₂.
Why some decimal fractions repeat forever in binary
Not every decimal fraction ends in binary. 0.1 becomes 0.000110011… forever, for the same reason 1/3 never ends in base 10; the fraction to decimal calculator shows that effect in decimal.
The tool keeps track of the remainders it has seen. When one comes back, it stops and marks the result "(Repeating pattern detected)" instead of running to the precision limit.
Precision and negative numbers
The "Fractional precision" box (default 8) caps how many binary digits after the point are worked out. Raise it for more accuracy on fractions that do not end.
A negative number is converted as its absolute value with a minus sign in front, so −10 becomes −1010. The tool does not produce two's complement bit patterns.
Powers of 2 in binary
Each power of 2 is a 1 followed by zeros, which makes these handy reference points. For any base from 2 to 36, use the base converter; all the conversions are listed on the number system converters page.
| Decimal | Binary | Decimal | Binary |
|---|---|---|---|
| 1 | 1 | 32 | 100000 |
| 2 | 10 | 64 | 1000000 |
| 4 | 100 | 128 | 10000000 |
| 8 | 1000 | 256 | 100000000 |
| 16 | 10000 | 1024 | 10000000000 |
Decimal to Binary Converter: FAQ
What is 255 in binary?
11111111, eight 1s. 255 = 128 + 64 + 32 + 16 + 8 + 4 + 2 + 1, the largest number one byte can hold.
Why is 0.1 not exact in binary?
0.1 = 1/10, and 10 has a factor of 5. A fraction in lowest terms ends in binary only when its denominator is a power of 2, so 0.1 repeats forever as 0.000110011…
Can it convert to octal or hex instead?
Yes. The Convert to menu also offers base 8 and base 16. The decimal to hexadecimal converter explains the divide-by-16 method on its own.
Sources
- Wikipedia: Binary number — converting whole numbers and fractions between decimal and binary (checked October 16, 2026)