Prime Checker
Test whether a number is prime, factorize it into primes, and list every prime up to a limit.
🔒 Runs entirely in your browser — nothing is uploadedPrimality and prime factorization
A prime number is a whole number greater than 1 that has exactly two divisors: 1 and itself. Numbers with more divisors are called composite, and the number 1 is neither. Primes are the building blocks of arithmetic because every integer above 1 can be written as a product of primes in exactly one way, a fact known as the fundamental theorem of arithmetic. This tool answers two everyday questions: is a given number prime, and what is its prime factorization? It tests primality by trial division against possible factors up to the square root of the number, which is enough to settle the question exactly.
The prime factorization breaks a composite number into the primes that multiply to make it, with repeated factors collected into exponents. For example, 360 = 2³ × 3² × 5. Factorizations are the practical heart of many tasks: they reveal the greatest common divisor and least common multiple of several numbers, they let you simplify fractions to lowest terms, and they underpin reasoning in cryptography and coding theory. The tool shows the factorization in a compact exponent form so it is easy to read and reuse.
Listing primes up to a limit
Enter an upper limit and the calculator lists every prime up to that value using the Sieve of Eratosthenes, a classic method that crosses out multiples of each prime in turn and keeps whatever remains. The sieve is efficient and produces the complete sequence 2, 3, 5, 7, 11, and so on, in order. Listing primes is useful for exploring patterns such as twin primes and prime gaps, for seeding tables in number-theory exercises, and for double-checking factorizations by hand.
Performance and privacy
Trial division and the sieve are exact for the moderate numbers used in schoolwork and everyday checks. Very large limits will use more memory and time, so increase the limit gradually if you notice a pause. JavaScript integers stay exact up to a large bound, beyond which you should verify results with arbitrary-precision software. Everything runs in your browser: the numbers you enter are never uploaded, stored or shared with any server.
How to use
- Check a numberEnter any whole number to test whether it is prime and to see its prime factorization.
- List primesEnter an upper limit to list every prime up to and including that value.
- Read the resultsSee the verdict, the factor breakdown, and the generated list of primes.