Prime Number Checker
Check if any number is prime and find prime factors instantly.
Enter a whole number such as 17 or 100. Decimals are not prime or composite in standard integer math.
Status
Prime
97 is prime because no whole number from 2 to √97 divides it evenly.
Input number
97
Square-root limit
9
Only divisors up to √n are needed.
Smallest divisor
—
Shown for composite numbers.
Factor pair
—
Previous prime
89
Next prime
101
Prime factorization
97
Factors
1, 97
Prime Number Rules
Prime number
A prime number has exactly two positive factors: 1 and itself.
Composite number
A composite number has more than two positive factors.
Neither
0 and 1 are neither prime nor composite.
Divisibility test
To check if n is prime, test divisors from 2 up to √n.
Prime result
If no divisor divides n evenly, n is prime.
Composite proof
If n = a × b where a and b are whole numbers greater than 1, then n is composite.
Variable Explanations
n
Number being checked.
Factor
A whole number that divides n evenly.
Divisor
A number used to test divisibility.
Remainder
Amount left after division.
√n
Square root of n.
Prime
Exactly two positive factors.
Composite
More than two positive factors.
What Prime Numbers Mean
Whole numbers greater than 1
Prime numbers are positive whole numbers greater than 1.
Exactly two factors
A prime has only 1 and itself as positive factors.
Composite breakdown
Composite numbers can be broken into smaller factor pairs.
Building blocks
Primes are building blocks of whole numbers.
Prime factorization
Every whole number greater than 1 is prime or can be factored into primes.
Useful in math
Primes matter in arithmetic, fractions, factorization, and computer science.
Worked Examples
Check 2
Divisibility check: Only check factors 1 and 2
Factor evidence: Factors are 1 and 2
Classification: Prime
2 is the only even prime number.
Check 17
Divisibility check: Check divisors up to √17
Factor evidence: 2, 3, and 4 do not divide 17 evenly
Classification: Prime
17 has exactly two positive factors.
Check 21
Divisibility check: Check divisibility
Factor evidence: 3 × 7 = 21
Classification: Composite
A factor pair greater than 1 proves it is composite.
Check 49
Divisibility check: Check divisibility
Factor evidence: 7 × 7 = 49
Classification: Composite
Square numbers can be composite when the square root is a whole number greater than 1.
Check 1
Divisibility check: Apply definition
Factor evidence: 1 has only one positive factor
Classification: Neither
Prime numbers need exactly two positive factors.
Check 100
Divisibility check: Even-number rule
Factor evidence: 2 × 50 = 100
Classification: Composite
Any even number greater than 2 is composite.
Check 97
Divisibility check: Check divisors up to √97
Factor evidence: No divisor from 2 to 9 divides evenly
Classification: Prime
Checking up to the square root is enough.
Check 84
Divisibility check: Prime factorization
Factor evidence: 84 = 2 × 2 × 3 × 7
Classification: Composite
Composite numbers can be broken into prime factors.
Prime vs Composite Numbers
Prime
13 is prime because its only positive factors are 1 and 13.
Composite
12 is composite because its factors include 1, 2, 3, 4, 6, and 12.
Neither
1 is neither prime nor composite because it has only one positive factor.
Factor Checks and Divisibility Rules
Divisible by 2
Even numbers are divisible by 2.
Divisible by 3
If the digit sum is divisible by 3, the number is divisible by 3.
Divisible by 5
Numbers ending in 0 or 5 are divisible by 5.
Divisible by 10
Numbers ending in 0 are divisible by 10.
Square-root limit
Checking up to √n is enough because factors come in pairs.
Factor pairs
A factor pair greater than 1 proves a number is composite.
Common Prime Number Mistakes
Frequently Asked Questions
Related tools