What makes a number prime
A prime number is a whole number greater than 1 whose only divisors are 1 and itself. The first few primes are 2, 3, 5, 7, 11, 13… Every other whole number greater than 1 is composite, meaning it can be written as a product of smaller primes.
To test a number you only need to try divisors up to its square root: if no factor exists below √n, none exists above it either, because factors come in pairs. The number 2 is the only even prime; 0 and 1 are neither prime nor composite.
Worked example
Is 97 prime?
How the check works
This tool uses trial division: it checks 2, then every odd number up to √n. If a divisor is found, the number is composite and the tool reports the smallest factor and the full prime factorization (for example 84 = 2² × 3 × 7). It also lists all divisors and finds the nearest primes on either side. Very large numbers are capped to keep the page fast, since trial division grows with √n.