ToolsVortex
Explore tools
Prime Factorization Calculator on ToolsVortex with a worked example filled in

Prime Factorization Calculator

ToolsVortex · Math & School

Type any whole number up to one trillion to break it into prime factors. You get exponent form, a factor tree, the division ladder, every divisor and whether the number is prime.

Prime factorization
2³ × 3² × 5
360 = 2 × 2 × 2 × 3 × 3 × 5
2^3 × 3^2 × 5Exponent form
CompositeType
24Number of divisors
1,170Sum of divisors
Factor tree
Division ladder
All divisors

Runs in your browser. Nothing you type is sent anywhere.

Prime Factorization Calculator on ToolsVortex with a worked example filled in
Prime Factorization Calculator: 360 shown as 2³ × 3² × 5 with its factor tree and 24 divisors.

This prime factorization calculator is for students learning factor trees, teachers making answer keys and anyone who needs the divisors of a number. It uses fast trial division in your browser, so even a 12 digit prime like 999,999,999,989 is checked in a fraction of a second.

What Is Prime Factorization?

Prime factorization writes a whole number as a product of prime numbers. For example, 360 = 2 × 2 × 2 × 3 × 3 × 5, or 2³ × 3² × 5 in exponent form. Every number above 1 has exactly one prime factorization, apart from the order, so it works like a fingerprint for that number.

How Do You Find the Prime Factorization of a Number?

You find it by dividing by the smallest prime that fits, again and again, until only 1 or a prime is left. A prime number has exactly two factors, 1 and itself (2, 3, 5, 7, 11 and so on), while a composite number has more. For 360: 360 ÷ 2 = 180, 180 ÷ 2 = 90, 90 ÷ 2 = 45, 45 ÷ 3 = 15, 15 ÷ 3 = 5, and 5 is prime. Drawn as branches this is a factor tree; written as a column of divisions it is called the ladder method. The tool shows both.

This method is called trial division. You only need to test primes up to the square root of the number, because if n had two factors both bigger than √n, their product would be bigger than n. For 10^12 that means testing up to 1,000,000, which a browser does almost instantly.

Why Does Every Number Have Only One Prime Factorization?

Every whole number above 1 has only one prime factorization because of the fundamental theorem of arithmetic, first proved in full by Carl Friedrich Gauss in 1801. It does not matter which factor you split off first: 360 = 4 × 90 or 360 = 10 × 36, but both trees end with three 2s, two 3s and one 5. This is why 1 is not counted as a prime; if it were, you could add any number of 1s and the factorization would no longer be unique.

How Do You Find the Number of Divisors From Prime Factors?

Add 1 to each exponent and multiply the results. This is the divisor function. For 360 = 2³ × 3² × 5¹, the count is (3 + 1)(2 + 1)(1 + 1) = 24 divisors. Each divisor picks 0 to 3 twos, 0 to 2 threes and 0 or 1 five. The same factors give the greatest common factor and least common multiple of two numbers: use the GCF calculator to take the smallest powers they share, or the LCM calculator to take the largest.

NumberPrime factorizationDivisorsSum of divisors
842² × 3 × 712224
1002² × 5²9217
1282⁷8255
2102 × 3 × 5 × 716576
3602³ × 3² × 5241,170
1,0017 × 11 × 1381,344
5,0402⁴ × 3² × 5 × 76019,344
720,7202⁴ × 3² × 5 × 7 × 11 × 132403,249,792
600,851,475,14371 × 839 × 1,471 × 6,85716610,544,148,480
1,000,000,000,0002¹² × 5¹²1692,499,694,822,171

Prime factors also explain square roots: a number is a perfect square only when every exponent is even, like 100 = 2² × 5², whose root is 2 × 5 = 10. The square root calculator shows this for any number.

Worked Example

A teacher wants to split 360 stickers into equal packs and needs every possible pack size. Enter 360: the tool shows 2³ × 3² × 5 and lists all 24 divisors, from 1, 2, 3, 4, 5, 6, 8, 9, 10, 12 up to 180 and 360. The factor tree shows 360 splitting into 2 and 180, then 2 and 90, then 2 and 45, then 3 and 15, then 3 and 5. Try a 12 digit number such as 600851475143 and it returns 71 × 839 × 1,471 × 6,857 with 16 divisors.

How Do You Use the Prime Factorization Calculator?

  1. Enter a whole number

    Type any whole number from 2 to 1,000,000,000,000. Commas and spaces are ignored.

  2. Read the prime factors

    The big result shows the factorization in exponent form, with the full product below it.

  3. Follow the factor tree

    The tree and the division ladder show each prime split off in order.

  4. See every divisor

    The divisor list shows all factors of the number, with the count and sum above.

How to use the Prime Factorization Calculator, steps 1 to 4 numbered on the tool
The numbers on the picture match the steps above.

Frequently Asked Questions

What is the prime factorization of 100?

The prime factorization of 100 is 2 × 2 × 5 × 5, written 2² × 5². Divide 100 by 2 to get 50, by 2 again to get 25, then by 5 to get 5, which is prime. 100 has 9 divisors.

Is 1 a prime number?

No. A prime has exactly two different factors, 1 and itself, and 1 has only one factor. Leaving 1 out keeps every prime factorization unique, which is the point of the fundamental theorem of arithmetic.

How do I know if a large number is prime?

Test whether any prime up to its square root divides it. If none does, the number is prime. For 999,999,999,989 that means testing up to about 1,000,000, and this tool finds it is prime in well under a second.

What is the difference between factors and prime factors?

Factors are all numbers that divide evenly, so 12 has the factors 1, 2, 3, 4, 6 and 12. Prime factors are only the primes in its breakdown, 2 and 3, since 12 = 2² × 3.

Why does the calculator stop at one trillion?

Trial division up to 10^12 needs at most about 333,000 test divisions, which stays instant on a phone. JavaScript numbers are exact up to about 9 × 10^15, so 10^12 also keeps every factor and divisor sum exact.

How do you write prime factorization in exponent form?

Group equal primes and write how many times each appears as a power. 2 × 2 × 2 × 3 × 3 × 5 becomes 2³ × 3² × 5. A prime used once has no exponent written, though it is really to the power 1.

Sources and Further Reading

Related Tools

Last reviewed: October 2026