Prime Factorization Calculator – Factor Any Number
Find the prime factorization of any number showing all prime factors and powers.
About This Calculator
Find the prime factorization of any number showing all prime factors and powers. Use the calculator above for instant results.
Prime Factors and the Fundamental Theorem of Arithmetic
Prime factorization expresses an integer greater than 1 as a product of prime numbers. A prime has exactly two positive divisors, 1 and itself. Composite numbers can be broken into smaller factors, and those factors can be broken down again until every factor is prime.
The Fundamental Theorem of Arithmetic says that this prime factorization is unique apart from the order of the factors. For example, 360 can be grouped in many ways, but every complete prime factorization reduces to 23 × 32 × 5. Exponents compress repeated factors: 23 means three factors of 2.
A reliable manual method is repeated division by the smallest possible prime. Divide by 2 while the number is even, then test 3, 5, 7, and later primes. When the remaining quotient is prime, it becomes the final factor. You do not need to test every integer as a possible divisor; once trial division has passed the square root of the remaining number, that remaining number must be prime.
Prime factorizations make several other number-theory operations transparent. The greatest common divisor uses the prime factors shared by two numbers at the smaller exponent. The least common multiple uses every prime appearing in either number at the larger exponent. Perfect squares have even exponents in their prime factorization, while perfect cubes have exponents divisible by three.
Worked Examples
- 360 = 2^3 x 3^2 x 5
Answer: 2^3 x 3^2 x 5
- 100 = 2^2 x 5^2
Answer: 2^2 x 5^2
- 2310 = 2 x 3 x 5 x 7 x 11 (product of first 5 primes)
Answer: 2x3x5x7x11
Divide repeatedly by small primes.
- 756 = 2 × 378 = 22 × 189
- 189 = 33 × 7
Answer: 756 = 22 × 33 × 7
Multiplying 4 × 27 × 7 verifies the original number.
Factor 1024 by repeated division by 2.
- 1024 = 2 × 512 = 22 × 256 = …
Answer: 1024 = 210
This shows why exponent notation is useful when one prime factor repeats many times.
Who Uses This Calculator?
Number theory and factoring.
GCD, LCM, and crypto algorithms.
Explore number structure.
Understand RSA factoring difficulty.
Common Mistakes to Avoid
❌ 1 is not prime
Factorization starts at 2.
❌ Unique factorization theorem
Every integer > 1 has exactly one unique prime factorization.
❌ Including 1 as a prime factor
The number 1 is neither prime nor composite. Including arbitrary factors of 1 would destroy uniqueness, which is why prime factorizations contain primes greater than 1 only.
❌ Stopping at a composite factor
A factorization such as 84 = 6 × 14 is not yet a prime factorization. Continue until each factor is prime: 84 = 22 × 3 × 7.
Frequently Asked Questions
How does factorization work?
Divide by smallest prime (2) repeatedly, then 3, 5, 7... until quotient is 1.
GCD from factorization?
GCD = common prime factors at minimum powers.
LCM from factorization?
LCM = all prime factors at maximum powers.
Does every positive integer have a prime factorization?
Every integer greater than 1 has a unique prime factorization, apart from factor order. The integer 1 is the multiplicative identity and has no prime factors, so it is treated separately.
How can prime factorization identify a perfect square?
A positive integer is a perfect square exactly when every exponent in its prime factorization is even. For example, 900 = 22 × 32 × 52, so its square root is 2 × 3 × 5 = 30.
Why is checking up to the square root enough?
If a composite number n has a factor larger than √n, its paired factor must be smaller than √n. Therefore, if no prime at or below the square root divides n, no larger factor pair can exist.
How do exponents help find the number of divisors?
If n = paqb…, a positive divisor may use each prime with exponent from zero through its maximum. The divisor count is therefore (a+1)(b+1)…. For 72 = 2332, there are 4 × 3 = 12 positive divisors.
Formula Explorer connections
Interpretation: This formula uses integer divisibility, modular arithmetic, finite fields or coding relationships. Assumption: Inputs are usually integers with specific modulus or coprimality requirements. Cryptographic examples are educational and not a substitute for vetted security libraries.