Prime Number Checker

Test whether a number is prime and see its smallest factors when it isn't.

Enter your details and press Calculate to see results.

Formula

Trial division up to √n

Example

97 has no divisors between 2 and 9, so it is prime.

What makes a number prime

A prime has exactly two divisors: 1 and itself. The checker tests divisibility only up to √n because any factor larger than √n must pair with one smaller than it.

Frequently asked questions

Why is 1 not prime?

By definition primes need two distinct divisors. 1 has only one, which keeps factorizations like 6 = 2×3 unique.

What is the largest number I can test?

Values up to about 10¹⁵ respond instantly.