Is 21 a Prime Number?

NO — COMPOSITE NUMBER

No, 21 is not a prime number. It is a composite number divisible by 3 (21 = 3 × 7), with prime factorization 3 × 7.

Prime Factorization
3 × 7
Positive Divisors
4
Previous Prime
Next Prime

Step-by-Step Proof: Why 21 Is Not Prime

  1. 1

    Compute the square-root bound: ⌊√21⌋ = 4. If 21 is composite, at least one prime ≤ 4 must divide it.

  2. 2

    Testing primes in ascending order immediately finds a witness divisor: 21 ÷ 3 = 7 with remainder 0.

  3. 3

    Since 3 divides 21 evenly (1 < 3 < 21), 21 has more than two positive divisors (4 in total) and its complete prime factorization is 21 = 3 × 7.

Prime Factorization & All Factors of 21

Open 21 in Visual Factor Tree →

21 has 4 positive divisors with divisor sum σ(21) = 32 and aliquot sum s(21) = 11 (Deficient number).

1 3 7 21

Division Ladder

1. 21 ÷ 3 = 7
2. 7 ÷ 7 = 1

Mathematical Properties & Number Bases of 21

Semiprime Fibonacci Number
Parity
Odd
Aliquot Class
Deficient number
Twin Prime
No
Binary (Base 2)
10101
Octal (Base 8)
25
Hexadecimal (Base 16)
0x15

Test Another Number Instantly

Enter any integer (including 100+ digit BigInt numbers) to test primality in our full Prime Number Checker.

Frequently Asked Questions About 21

Is 21 a prime number or a composite number?

No, 21 is not a prime number. It is a composite number divisible by 3 (21 = 3 × 7), with prime factorization 3 × 7.

What are all the positive factors (divisors) of 21?

The 4 positive divisors of 21 are: 1, 3, 7, 21. Their sum is σ(21) = 32.

What is the prime factorization of 21?

The prime factorization of 21 is 3 × 7 (3 × 7).

What are the closest prime numbers before and after 21?

The previous prime before 21 is 19, and the next prime after 21 is 23.

← Previous curated number: 19 Next curated number: 23 →

Prime Number Tools & Reference Guides

Explore dedicated charts, visual factor trees, range generators, and step-by-step proofs for commonly searched numbers.