Prime Checker & Factorization

Check whether a number is prime, see its prime factorisation and every divisor, find the nearest primes either side, and list the primes between two numbers.

60 is not prime
Prime factors: 60 = 2² × 3 × 5
Divides by:1, 2, 3, 4, 5, 6, 10, 12, 15, 20, 30, 60
Nearest primes:before 59after 61
Primes between two numbers
25 primes
2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97

🔒 Checked in your browser — nothing is uploaded.

Prime or not, and the working

Type a whole number and the tool says in a sentence whether it is prime, and for a composite number shows the working underneath: 60 is not prime, and 60 = 2² × 3 × 5. Below that it lists what the number divides by, which is what makes an answer of not prime believable, and the nearest prime on either side of it. A separate section lists every prime between two numbers you choose. A number is prime when it is 2 or greater and has no divisors other than 1 and itself; 0, 1, negatives and decimals are not prime and have no factorization.

How far it goes, and how fast

It uses trial division up to the square root of the number, skipping everything that is not of the form 6k ± 1, so anything up to about a trillion resolves instantly and the largest whole number JavaScript can hold exactly — 9,007,199,254,740,991 — still resolves, if not quite instantly. The divisor list appears for numbers with at most 200 divisors, since a longer list is neither useful on a page nor cheap to build, and the first 24 are shown with a count of the rest. The range section spans up to a million numbers and lists the first 500 primes it finds in that span, ready to copy.

Why factorization matters

Prime factorization is the backbone of number theory and shows up everywhere from simplifying fractions and finding least common multiples to understanding how encryption keys are built. Because every integer greater than 1 has a unique prime factorization, the breakdown you see here is the one and only correct answer for that number. Everything is computed locally in your browser, so you can check as many numbers as you like without limits.

Frequently asked questions

How large a number can I check?

Up to 9,007,199,254,740,991 — the largest integer JavaScript represents exactly, so beyond it an answer would be quietly wrong rather than slow, and the tool says so instead of guessing. Trial division runs only as far as the square root, so anything up to about a trillion answers instantly.

How do I know it is really not prime?

The page shows the factorisation and the list of divisors, so the claim can be checked rather than trusted: 91 is not prime because 91 = 7 × 13, and 1, 7, 13 and 91 are what it divides by. For a prime, the divisor list is just 1 and the number itself.

Can it list the primes in a range?

Yes. The section below takes a start and an end and lists every prime between them, with a count and a copy button. The span can be up to a million numbers wide and the first 500 primes found are listed; narrow the range if you need the ones after that.

Is my number sent to a server?

No. Everything runs entirely in your browser using JavaScript. Nothing you type is uploaded, logged or stored anywhere.