Prime Number Checker

Check whether a number is prime and find its smallest divisor.

Result

Result

Prime

Smallest divisor

97

How it works

Prime = divisible only by 1 and itself

A prime number has exactly two divisors: one and itself. Two, three, five, seven, eleven — and two is the only even prime, since every other even number is divisible by two. One is deliberately excluded. It has only a single divisor, and admitting it would break the fundamental theorem of arithmetic, which says every integer above one factors into primes in exactly one way. With one allowed, 6 could be 2×3 or 1×2×3 or 1×1×2×3, and uniqueness would collapse. Primes are the atoms of the integers, and they thin out without ever running out — Euclid proved there are infinitely many. Their difficulty is now infrastructure: modern encryption rests on the fact that multiplying two large primes is easy while recovering them from the product is, so far as anyone knows, not.

Advertisement

Frequently asked questions

Is 1 a prime number?

No — a prime needs exactly two distinct divisors, and 1 has only one.

What is the smallest prime?

2 — and it's the only even prime.

How far do I need to test for divisors?

Only up to the square root of the number. If n has a divisor larger than √n, it must have a matching one smaller — so finding none below the root proves the number is prime. That single insight makes primality testing practical.

Advertisement

Related calculators