Prime factorization calculator
Break a number into prime factors, check if it is prime, list divisors and find GCD and LCM.
Runs in your browser – your files are not uploaded
How to use Prime factorization calculator
- 1
Enter a whole number of 2 or more.
- 2
Read the prime factorization, the prime check and the list of divisors.
- 3
Switch to GCD & LCM and enter several numbers to find their common divisor and multiple.
About Prime factorization calculator
Enter a whole number to see its prime factorization in exponent form, such as 360 = 2³ × 3² × 5. The calculator also tells you whether the number is prime, how many divisors it has and lists them all.
Factorization uses exact trial division in your browser and works for numbers up to 10¹⁵ (one quadrillion) – larger numbers are rejected with a clear message rather than freezing your browser. The GCD and LCM mode accepts any number of integers of any size.
Frequently asked questions
Why is there a limit of 10¹⁵?
Trial division has to test divisors up to the square root of the number. Up to 10¹⁵ that takes well under a second in the browser; much larger numbers would need specialised algorithms.
Is 1 a prime number?
No. A prime has exactly two different divisors, 1 and itself. The number 1 has only one divisor, so it is neither prime nor composite.
How are GCD and LCM calculated?
The GCD uses the Euclidean algorithm; the LCM is built from it (a × b ÷ GCD). Both use arbitrary-precision integers, so the LCM can be very large.