Education

Prime Number Checker

Enter any non-negative whole number to find out whether it is prime. If it is composite, the tool shows its prime factorization and full list of divisors using efficient trial division up to the square root. Works on large integers and runs entirely in your browser.

Examples

Input · Composite numbers show their full prime factorization.
84
Output
Not prime — 2^2 × 3 × 7

How it works

The number is tested by trial division: it is divided by 2 and then by every odd number up to its square root. If none divides evenly, it is prime. No divisor larger than the square root needs checking, because it would have to pair with a smaller one already tried.

Examples
NumberResult
97Prime
91Not prime: 7 × 13
84Not prime: 2^2 × 3 × 7
1Neither prime nor composite

For a number that is not prime you also get its prime factorization and its divisors, with the first 24 listed when there are many. Whole numbers up to 9,007,199,254,740,991 are accepted; a very large prime near that limit takes tens of millions of divisions, so allow it a moment.

How to use Prime Number Checker

Type a number
Enter any non-negative whole number you want to check.
See the verdict
The tool instantly tells you whether it is prime, composite, or neither.
Inspect the factors
For composite numbers, view the prime factorization and full divisor list.

Why use this tool

Instant prime or composite verdict
Shows prime factorization for composites
Lists all divisors of the number
Efficient trial division handles large integers

Frequently asked questions

No. Zero and one are neither prime nor composite, and the tool labels them accordingly.

Any whole number up to JavaScript's safe integer limit (about 9 quadrillion) is supported via trial division.

Found a bug or have an idea?

ToolOrbit is actively developed — feedback directly shapes what gets built next.

Send feedback