Factor Calculator
Creator
Reviewer
Type any positive whole number and press Calculate. This factor calculator lists every factor it has, from 1 up to the number itself, pairs those factors so you can see which two numbers multiply together to make it, tells you straight away whether the number is prime or composite, and for composite numbers shows the prime factorization and a factor tree.
What is a factor of a number?
A factor of a number is any whole number that divides into it evenly, with nothing left over. If you divide 12 by 3, you get exactly 4, with no remainder, so 3 is a factor of 12 (and so is 4). Every whole number greater than 0 has at least two factors of its own, 1 and itself, since dividing any number by 1 or by itself always comes out even.
Finding every factor of a number by hand means checking each whole number in turn to see whether it divides evenly, but you do not need to check all the way up to the number itself. Once you have checked every candidate up to its square root, every remaining factor is just the complement of one you already found: if a divides n evenly, then n divided by a is also a factor, and one of that pair is always at or below the square root. That shortcut, trial division up to the square root, is exactly how this calculator finds the complete list without checking every number in between.
How factor pairs work, with 36 as an example
A factor pair is simply two factors that multiply together to give the original number. Take 36. Checking every whole number from 1 up to its square root (6) for an even division gives:
- 1 × 36 = 36
- 2 × 18 = 36
- 3 × 12 = 36
- 4 × 9 = 36
- 6 × 6 = 36
Reading off every number that appeared in those pairs and sorting them gives the complete factor list for 36: 1, 2, 3, 4, 6, 9, 12, 18, 36, nine factors in total. Notice that 6 only appears once even though it shows up on both sides of its pair (6 × 6); a factor is only ever listed once, no matter how many pairs it belongs to. That is also the giveaway that 36 is a perfect square, since perfect squares are the only numbers whose square root pairs with itself.
Factor pairs are useful well beyond textbook exercises. They come up whenever you need to arrange a fixed quantity into equal rows and columns, such as laying out 36 chairs into an even grid (6 rows of 6, 4 rows of 9, 2 rows of 18, and so on), and they are the starting point for simplifying fractions, since a fraction reduces fully once you divide its numerator and denominator by a shared factor pair.
Prime numbers versus composite numbers
Once you have a number's complete factor list, checking whether it is prime or composite is just a matter of counting. A prime number has exactly two factors, 1 and itself, and nothing in between; 13, 17, and 29 are all prime because no smaller whole number divides into them evenly. A composite number has more than two factors; 36, with nine factors, is a good example, and so is 12, with six. The number 1 is a special case that fits neither definition: it has only one factor (itself), so it is conventionally treated as neither prime nor composite.
This tool leads with a slightly different question from the Prime Factorization Calculator. This page's headline result is every factor a number has, the full set of divisors, including composite ones like 4 or 6. For a composite number it also shows the prime factorization and a factor tree right alongside that list, the smallest possible pieces the number can be multiplied from, for example writing 36 as 2 × 2 × 3 × 3. The two results are closely related (every factor of 36 can be built by multiplying some combination of those prime factors together); reach for the dedicated Prime Factorization Calculator instead when exponent form (2^2 × 3^2) or a general explanation of why that breakdown is unique is what you actually need.
Counting factors from the prime factorization
You can count a number's factors without listing them. Write the number as a product of prime powers, add 1 to each exponent, and multiply the results.
where:
- n
- The number being factored
- p_i
- The distinct primes that divide n
- a_i
- How many times each prime divides n
- d(n)
- The number of factors of n, counting 1 and n itself
For 72, the prime factorization is 2^3 × 3^2, so the count is (3+1)(2+1) = 12. Listing the factors confirms it: 1, 2, 3, 4, 6, 8, 9, 12, 18, 24, 36, and 72. A prime p is just p^1, which gives (1+1) = 2 factors. A perfect square has an odd count because every exponent in its factorization is even, so every term in the product is odd.
Where factoring shows up outside the classroom
Factor lists and factor pairs are not just a homework exercise; they turn up whenever a fixed quantity has to be split evenly. Splitting a bill of $36 evenly among a group of friends only works out to a whole number of dollars per person if the group size is one of 36's factors, 2, 3, 4, 6, 9, 12, or 18 people, for example, rather than 5 or 7. Arranging seating, packing identical boxes into a shipment, or scheduling a task that has to repeat on a regular cycle all lean on the same idea: the factor pairs of a number are every way to arrange that quantity into an even grid or an even split.
Factor lists are also the foundation for simplifying fractions and ratios. A fraction like 18/24 reduces to 3/4 because 6 is a common factor of both the numerator and the denominator; dividing both sides by their largest shared factor is exactly what a greatest common factor tool does, and it depends on knowing the full factor list of each number involved. In the other direction, finding a common denominator for two fractions with different bottoms usually means finding a shared multiple of both, which is what a least common multiple tool solves. Both of those calculators compare two or more numbers against each other; this one stays focused on a single number and everything that divides it.
Trial division, the method this calculator uses, checks every whole number from 1 up to the square root of your input to see whether it divides evenly. For a number in the hundreds or low thousands that finishes instantly, but the amount of work grows with the square root of the input, so a number in the millions takes meaningfully longer to check than one in the thousands. That growth curve is the reason this tool caps its input at 1,000,000: past that point, trial division stops being instant and starts being a genuinely slow computation for a page that is meant to answer as you type.
Tips for using this factor calculator
Type the number as plain digits, without commas, spaces, or a currency symbol; 1000000 is read correctly, while 1,000,000 may not parse the way a spreadsheet cell would. Only positive whole numbers are accepted, so a decimal like 12.5 or a negative number like -12 returns a message asking for a valid whole number rather than guessing at the nearest integer. The upper limit is 1,000,000: entering a number larger than that returns a message about the input being out of range rather than letting the page freeze while trial division works through an enormous search space. There is no lower limit beyond 1 itself, since 1 is a valid, if unusual, input: it has exactly one factor, itself, and is neither prime nor composite, a case this calculator reports plainly rather than forcing it into one category or the other.
Verifying a result by hand
Multiplying every entry in a factor pair back together is a fast way to sanity-check any result from this tool. For 84, the pairs are 1 and 84, 2 and 42, 3 and 28, 4 and 21, 6 and 14, and 7 and 12, each multiplying back to 84 exactly, giving the full factor list 1, 2, 3, 4, 6, 7, 12, 14, 21, 28, 42, 84, twelve factors in total. Since 84 is even, 2 is guaranteed to be a factor before any calculation runs; since its digits sum to 12, which is divisible by 3, 3 is also guaranteed to be a factor. Those two quick divisibility checks, an even last digit for 2 and a digit sum divisible by 3 for 3, are worth knowing by heart for spot-checking any factor list at a glance.
Divisibility tests extend that spot-check to other small factors. Each rule below works on the digits alone, so no long division is needed.
| Rule | Worked example |
|---|---|
| 2 is a factor of a number when its last digit is even. | 3,846 ends in 6, and 3,846 = 2 × 1,923. |
| 3 is a factor of a number when its digits add up to a multiple of 3. | 7 + 2 + 1 + 5 = 15, so 7,215 = 3 × 2,405. |
| 4 is a factor of a number when its last two digits form a multiple of 4. | 16 is 4 × 4, so 5,316 = 4 × 1,329. |
| 5 is a factor of a number when its last digit is 0 or 5. | 8,745 ends in 5, and 8,745 = 5 × 1,749. |
| 6 is a factor of a number when it is even and its digits add up to a multiple of 3. | 4,518 is even and 4 + 5 + 1 + 8 = 18, so 4,518 = 6 × 753. |
| 8 is a factor of a number when its last three digits form a multiple of 8. | 128 is 8 × 16, so 9,128 = 8 × 1,141. |
| 9 is a factor of a number when its digits add up to a multiple of 9. | 6 + 3 + 8 + 1 = 18, so 6,381 = 9 × 709. |
| 10 is a factor of a number when its last digit is 0. | 2,470 ends in 0, and 2,470 = 10 × 247. |
| 12 is a factor of a number when both 3 and 4 are factors of it. | 1,356 passes the 3 test (digit sum 15) and the 4 test (56 = 4 × 14), so 1,356 = 12 × 113. |
Quick factor lists for a few more numbers
Seeing a few more examples side by side helps when learning how to factor a new number quickly, without working through the full trial-division steps each time. The factors of 30 are 1, 2, 3, 5, 6, 10, 15, and 30, coming from the pairs 1 × 30, 2 × 15, 3 × 10, and 5 × 6. The factors of 16 are 1, 2, 4, 8, and 16, an odd count of five because 16 is a perfect square, its own square root pairing with itself instead of a different number. The factors of 20 are 1, 2, 4, 5, 10, and 20, coming from the pairs 1 × 20, 2 × 10, and 4 × 5. Writing any of these numbers in factored form, such as 20 as 2 × 2 × 5 or 30 as 2 × 3 × 5, is simply the prime-factorization version of the same idea, broken down one step further than a plain factor pair.
Factor chart for the numbers people look up most
The chart below lists every factor of 24 numbers that come up often in homework and in everyday splitting problems. Each row comes from the same trial-division routine that runs the calculator above, so the two cannot disagree. A count of 2 marks a prime number, and an odd count marks a perfect square.
| Look-up | All factors | Count |
|---|---|---|
| Factors of 4 | 1, 2, 4 | 3 |
| Factors of 6 | 1, 2, 3, 6 | 4 |
| Factors of 8 | 1, 2, 4, 8 | 4 |
| Factors of 9 | 1, 3, 9 | 3 |
| Factors of 10 | 1, 2, 5, 10 | 4 |
| Factors of 13 | 1, 13 | 2 |
| Factors of 15 | 1, 3, 5, 15 | 4 |
| Factors of 17 | 1, 17 | 2 |
| Factors of 21 | 1, 3, 7, 21 | 4 |
| Factors of 22 | 1, 2, 11, 22 | 4 |
| Factors of 25 | 1, 5, 25 | 3 |
| Factors of 26 | 1, 2, 13, 26 | 4 |
| Factors of 27 | 1, 3, 9, 27 | 4 |
| Factors of 34 | 1, 2, 17, 34 | 4 |
| Factors of 35 | 1, 5, 7, 35 | 4 |
| Factors of 39 | 1, 3, 13, 39 | 4 |
| Factors of 40 | 1, 2, 4, 5, 8, 10, 20, 40 | 8 |
| Factors of 44 | 1, 2, 4, 11, 22, 44 | 6 |
| Factors of 49 | 1, 7, 49 | 3 |
| Factors of 50 | 1, 2, 5, 10, 25, 50 | 6 |
| Factors of 52 | 1, 2, 4, 13, 26, 52 | 6 |
| Factors of 70 | 1, 2, 5, 7, 10, 14, 35, 70 | 8 |
| Factors of 80 | 1, 2, 4, 5, 8, 10, 16, 20, 40, 80 | 10 |
| Factors of 120 | 1, 2, 3, 4, 5, 6, 8, 10, 12, 15, 20, 24, 30, 40, 60, 120 | 16 |
Frequently asked questions
Why isn’t 1 considered a prime number?
What does a perfect square’s factor list look like?
What is the largest number this calculator can factor?
How is this different from the Prime Factorization Calculator?
How does the factor tree get built?
Can a negative number or a fraction have factors?
How many factors does a prime number always have?
Why do some numbers have so many more factors than others of a similar size?
What are the factors of a number, exactly?
What is this tool called elsewhere, like "list of factors" or "divisor calculator"?
What are the factors of 12?
How do I find factors of a number without a calculator?
Related tools: Binary Calculator, Root Calculator and Fraction Calculator. More are grouped under Math Calculators, and every tool on the site is listed at all calculators.
