How to use the Base 5 to Binary tool
- Enter a number made of the digits 0 to 4 in the Base-5 number box. The Example button loads 140.
- Select Convert to calculate the value.
- Read the binary result in the Result box. The example 140 converts to 101101.
- Select Copy to copy it, or Clear to try another quinary number.
How base 5 to binary conversion works
Quinary notation groups by fives. Its place values are 1, 5, 25, 125, 625 and onward, and each place holds a digit from 0 to 4. To convert, the tool reads the digits from the left, multiplies its running total by 5 before adding each new digit, and then writes the final total in base 2.
Five is odd and has no factor in common with two, so there is no fixed bit pattern per digit. A single quinary digit is worth about 2.32 bits. In practice a five-digit quinary number needs up to 12 bits and a ten-digit one up to 24.
Worked example: 2043 in quinary
Multiply each digit by its place value: 2 × 125 + 0 × 25 + 4 × 5 + 3 = 273. Then break 273 into powers of two. It is 256 + 16 + 1, so bits 8, 4 and 0 are set and the rest are zero.
2043 (base 5) = 2*125 + 0*25 + 4*5 + 3 = 273
273 (base 10) = 100010001 (base 2)Checking a result with powers of five
Round numbers in base 5 are powers of five, and their binary forms are worth knowing as reference points. Quinary 10 is five (101), 100 is twenty-five (11001) and 1000 is one hundred twenty-five (1111101).
The value just below a power is all 4s. Quinary 444 is 124, one less than 125, so its binary form 1111100 is one less than 1111101. No three-digit quinary input can produce a result above 1111100.
Parity gives another quick test. Because 5 is odd, a quinary number is even exactly when the sum of its digits is even. For 140 the digits add to 5, which is odd, and the binary result 101101 ends in 1 as expected.
Where quinary counting comes from
Base 5 follows the fingers of one hand. Tally marks are bundled in fives, and the abacus combines fives and ones: on a Japanese soroban, each rod has one bead worth five and four beads worth one. That mixed scheme is called bi-quinary, and some early decimal computers, including the IBM 650, stored digits in a bi-quinary code. Pure base 5 is rare in software, so it mostly appears in coursework and conversion tests.
Input limits and errors
The box accepts one whole number of up to 4,096 characters, with an optional leading minus sign. Big-integer math keeps every bit exact at that size. Digits 5 to 9 are out of range: entering 125 returns Invalid base-5 digit: 5. Spaces inside the number, commas and decimal points fail the same way. A negative input keeps its sign, so -34 becomes -10011.
Frequently asked questions
Which digits can a base 5 number use?
The digits 0, 1, 2, 3 and 4. The digit 5 itself is never valid, because five is written as 10 in quinary, one five and zero units.
What is quinary 140 in binary?
It is 101101. The quinary digits mean 1 × 25 + 4 × 5 + 0, which is 45, and 45 in binary is 32 + 8 + 4 + 1.
Can I convert each base 5 digit to bits separately?
No. That only works for bases that are powers of two, such as 4, 8 and 16. For base 5 the whole number has to be evaluated, because a carry from one digit affects many bits.
Does it handle negative quinary numbers?
Yes. Put a minus sign before the digits. The result is the minus sign followed by the binary magnitude. The tool does not produce two's complement, since it has no fixed word size.
What is the reverse of this conversion?
The Binary to Base 5 tool takes a binary whole number and prints it in quinary. Converting a result there should return your original digits, minus any leading zeros.