Prime Factorization Calculator

Break any whole number into its prime factors, written with exponents, and check whether it is prime.

Reviewed by the WorldCalcs team · Methodology · Last reviewed: June 2026

Result

360 = 2³×3²×5

Distinct prime factors: 2, 3, 5

360 is a composite number.

What is prime factorization?

Prime factorization breaks a whole number down into the prime numbers that multiply together to make it. A prime number is a whole number greater than 1 whose only divisors are 1 and itself (2, 3, 5, 7, 11, and so on). Every whole number greater than 1 has exactly one prime factorization, a result known as the fundamental theorem of arithmetic. Writing a number this way is the foundation for simplifying fractions, finding the greatest common factor and least common multiple, and working with roots and exponents.

How it's calculated

Start with the smallest prime, 2, and divide as many times as it goes in evenly. Move to the next prime (3, then 5, 7, and so on) and repeat, each time dividing out every copy of that prime. You only need to test primes up to the square root of the number; if nothing divides it by then, whatever remains is itself prime. The exponent on each prime simply counts how many times it appears.

Example

Take 360. It is even, so divide by 2 three times: 360, 180, 90, 45. Now 45 is divisible by 3 twice: 45, 15, 5. Finally 5 is prime. So 360 = 2 × 2 × 2 × 3 × 3 × 5, written with exponents as 2³ × 3² × 5.

All calculations happen in your browser. Nothing is sent, stored, or tracked.

Results are estimates and may contain errors — for general information only, not professional advice. Always verify before relying on them. Disclaimer

How to use

Enter any positive whole number from 2 up to 1,000,000,000,000. The calculator divides it by primes 2, 3, 5, 7, ... until nothing is left, then writes the result with exponents.

If the number is prime, the result is just the number itself. The list of distinct prime factors is shown below the factorization.

Frequently asked questions

Is 1 a prime number?+

No. A prime must have exactly two distinct divisors, 1 and itself; the number 1 has only one divisor, so it is neither prime nor composite.

What is the difference between factors and prime factors?+

Factors are all the numbers that divide evenly into a number (for 12: 1, 2, 3, 4, 6, 12). Prime factors are only the prime ones, and the prime factorization writes the number as their product (12 = 2² × 3).

What is the prime factorization of a prime number?+

It is just the number itself, for example 17 = 17.

How do prime factors help find the GCF and LCM?+

The greatest common factor multiplies the primes shared by both numbers using the lowest powers; the least common multiple uses every prime that appears using the highest powers. See our GCF & LCM Calculator.

Can decimals or negative numbers be factorized?+

Prime factorization is defined for whole numbers greater than 1, so this tool works with positive whole numbers only.