Home › Calculators › Prime Number Calculator

Prime Number Calculator

Enter any whole number to test primality. Composite numbers get their prime factorisation; enter 1,000,000 or less and you also get the count of primes below it and the largest one — all computed with an exact sieve, never guessed.

What "prime" means

A prime has exactly two divisors: 1 and itself. 2 is the only even prime; 1 is not prime at all.

How it checks

Trial division up to the square root for the primality test, and the Sieve of Eratosthenes for listing — the same algorithms textbooks teach, run exactly.

Why primes matter

Modern encryption (RSA) multiplies huge primes together — easy to multiply, practically impossible to factor back. Your bank login leans on primes.

Frequently Asked Questions

What is a prime number?

A whole number greater than 1 divisible only by 1 and itself: 2, 3, 5, 7, 11…

Is 1 a prime number?

No — primes need exactly two divisors, and 1 has only one.

Related Tools

Age Calculator — Your exact age in years, months and days — plus days lived and next birthday.

BMI Calculator — Body Mass Index with WHO weight categories — metric or imperial.

Mortgage Calculator — Monthly payment, total interest and payoff date for any home loan.

Loan EMI Calculator — EMI, total interest and total payable for car, personal and home loans.

Compound Interest Calculator — See what your money becomes — compound growth at any frequency.

Fraction Calculator — Add, subtract, multiply and divide fractions — mixed numbers welcome.

Fraction, Decimal & Percent Converter — Any one form in — all three forms out, fractions properly simplified.

Body Fat Calculator — US Navy tape-measure method — body fat % from a few measurements.

Weight Loss Calculator — A realistic weekly plan — weight to lose, daily deficit, target date.

Decimal Calculator — Exact decimal arithmetic — no 0.30000000000000004 surprises.

Calorie Calculator — Daily calorie needs from the Mifflin-St Jeor equation.

Recurring Deposit Calculator — RD maturity value with quarterly compounding, the bank way.

Percentage Calculator — X% of Y, X as a % of Y, and percent change — three tools in one.

Variance & Statistics Calculator — Mean, median, mode, variance and standard deviation in one paste.

Ratio Calculator — Simplify ratios and solve for the missing part.

Budget Calculator (50/30/20) — Split your take-home pay into needs, wants and savings.

Target Heart Rate Calculator — Karvonen training zones from your age and resting heart rate.

Savings Calculator — What monthly savings become — future value with compound growth.

Date Calculator — Add or subtract days from any date, and find the days between two dates.

Corrected Calcium Calculator — Correct total calcium for low albumin — the standard bedside formula.

A1C to Average Glucose Calculator — Convert HbA1c % into estimated average glucose (eAG) — mg/dL and mmol/L.