Prime Factorization Calculator
Find the prime factorization of any number. Shows all prime factors, exponents, and factor trees.
| Prime Factor | Exponent | Value (pⁿ) |
|---|
Break any whole number down into its prime factors, see the exponent form and factor tree, and instantly check whether the number itself is prime.
How Prime Factorization Calculator Works
The calculator uses trial division: it repeatedly tests divisors starting at 2, dividing the number by each one as many times as it evenly fits before moving to the next divisor, only checking up to the square root of the remaining value. Whatever is left over at the end — if greater than 1 — is itself a prime factor.
The result is expressed in exponent form, such as 2³ × 3² × 5, where each prime is raised to how many times it divides the number. The factor tree shows the same breakdown as a sequence of divisions, and a number is flagged as prime only when it has exactly one distinct prime factor with an exponent of 1 — meaning nothing else divides it.
Two counts are shown side by side: the number of prime factors "with multiplicity" (every repeated prime counted separately, e.g. 2, 2, 2 counts as three) versus "distinct primes" (unique prime values only, e.g. just 2). The sum-of-prime-factors figure totals each prime factor as many times as it appears.
See It In Action
Who Uses Prime Factorization Calculator and Why
- Breaking a number down into its prime building blocks before simplifying a radical or fraction.
- Checking quickly whether a number is prime by seeing if its factorization has just one distinct prime with an exponent of 1.
- Cross-checking an LCM or GCF calculation manually by comparing the prime factorizations of the numbers involved.
- Working through a factor-tree exercise for a math class, seeing the same breakdown as a sequence of divisions.
Mistakes to Avoid
- Mixing up "with multiplicity" and "distinct primes" counts — for 360 = 2³×3²×5 that's 6 factors with multiplicity but only 3 distinct primes, and the two numbers answer different questions.
- Assuming the number 1 has its own prime factorization — 1 has no prime factors at all, since it isn't prime or composite.
- Forgetting that the leftover value after dividing out all found factors, if greater than 1, is itself a prime factor — not an error or incomplete result.
Tips for Best Results
- Use the exponent form (like 2³ × 3² × 5) directly when you need to find the LCM or GCF of that number against another by comparing prime exponents.
- Use the distinct-prime count to spot square-free numbers — a number with no repeated prime factor in its factorization.
Fixing Common Problems
The number is flagged as prime but I expected it to be composite (or vice versa). — Check the factorization result directly: exactly one distinct prime factor with an exponent of 1 means prime; anything else means composite.
A very large number is taking a while to factor. — Trial division checks divisors up to the square root of the remaining value, so factoring a large number (especially one with only large prime factors) naturally takes longer.
Terms Explained
Trial division: A factoring method that tests successive divisors starting at 2, dividing them out as many times as they fit before moving to the next candidate.
Multiplicity: How many times a given prime factor appears in a number's factorization, as opposed to counting each distinct prime only once.