Prime Number Checker

Check if a number is prime, find its factors, and discover nearby primes

Check a Number

Find Primes in Range

What is a Prime Number?

A prime number is a natural number greater than 1 that has no positive divisors other than 1 and itself. In other words, a prime number can only be divided evenly by 1 and the number itself.

Prime Numbers

Examples: 2, 3, 5, 7, 11, 13, 17, 19, 23...

  • 2 is the only even prime
  • Divisible only by 1 and itself
  • Building blocks of all numbers

Composite Numbers

Examples: 4, 6, 8, 9, 10, 12, 14, 15...

  • Have more than 2 factors
  • Can be factored into primes
  • 4 = 2 x 2, 12 = 2 x 2 x 3

Special Case: 1 is NOT Prime

By definition, 1 is neither prime nor composite. It's a "unit" - the multiplicative identity.

First 100 Prime Numbers

2357111317192329313741434753596167717379838997101103107109113127131137139149151157163167173179181191193197199211223227229233239241251257263269271277281283293307311313317331337347349353359367373379383389397401409419421431433439443449457461463467479487491499503509521523541

Interesting Prime Number Facts

Twin Primes

Pairs of primes that differ by 2: (3,5), (5,7), (11,13), (17,19)...

Mersenne Primes

Primes of the form 2^n - 1: 3, 7, 31, 127, 8191...

Prime Gap

Gaps between consecutive primes grow larger, but primes are infinite.

Cryptography

Large primes are crucial for RSA encryption and online security.

How to Check if a Number is Prime

  1. Is it less than 2? If yes, it's not prime.
  2. Is it 2? If yes, it's prime (the only even prime).
  3. Is it even? If yes and greater than 2, it's not prime.
  4. Check divisibility: Test odd numbers from 3 up to √n. If any divide evenly, it's not prime.
  5. Passed all tests? The number is prime!

Example: Is 29 prime?
√29 ≈ 5.4, so check: 3, 5
29 ÷ 3 = 9.67 (not even)
29 ÷ 5 = 5.8 (not even)
→ 29 is PRIME

Frequently Asked Questions

Related Calculators