List of prime numbers

Choose a range of up to 10,000 numbers, anywhere below one trillion. The 25 primes below 100 are shown first.

Every prime in the range, found by a segmented sieve of Eratosthenes and exact. Copy puts the list on your clipboard, separated by commas.

The prime numbers from 1 to 100

There are 25 primes below 100:

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

The number 1 is not on the list: a prime must have exactly two divisors, and 1 has only one (Prime numbers). 2 is the only even prime, since every other even number is divisible by 2. Every number from 2 to 100 that is not listed is composite, and has a prime factor of 2, 3, 5 or 7 (the primes up to √100 = 10).

The 168 primes below 1000

The count of primes in each hundred falls from 25 (1 to 100) to 21, 16, 16, 17, 14, 16, 14, 15 and 14 (901 to 1000). Primes thin out slowly as numbers grow: near x, about one number in ln x is prime[1].

The 168 prime numbers below 1000, ten to a row
2357111317192329
31374143475359616771
7379838997101103107109113
127131137139149151157163167173
179181191193197199211223227229
233239241251257263269271277281
283293307311313317331337347349
353359367373379383389397401409
419421431433439443449457461463
467479487491499503509521523541
547557563569571577587593599601
607613617619631641643647653659
661673677683691701709719727733
739743751757761769773787797809
811821823827829839853857859863
877881883887907911919929937941
947953967971977983991997

How the list is made

The tool uses a segmented sieve of Eratosthenes[1]. To list the primes from a to b, it first finds every prime up to √b (at most one million, since b is at most 1012), then crosses out their multiples inside the window, starting each prime p at the first multiple that is at least a and at least p2. Whatever is left in the window is prime. Every whole number in the window is examined, so the list is exact and complete. The window is limited to 10,000 numbers so that the table stays readable and the page stays quick; the arithmetic itself is exact well beyond that.

Two checks you can make: there are exactly 168 primes below 1000 and 78,498 below one million[2]. The ranges just above a million and just below a trillion show how much sparser primes are up there: about one number in 14 near a million, and one in 28 near a trillion.

Sources

  1. Victor Shoup (2008). A Computational Introduction to Number Theory and Algebra, 2nd edition (Version 2, free PDF). Cambridge University Press. ISBN 9780521516440. textbook
  2. The OEIS Foundation (2025). A006880: Number of primes < 10^n (π(10^n)). The On-Line Encyclopedia of Integer Sequences. database