Is 123 a Prime Number?
Updated · exact integer math
No, 123 is not a prime number. It's composite.
123 = 3 × 41
Why 123 is not prime
Its digits add up to 6, which is divisible by 3, so 123 is too: 123 ÷ 3 = 41.
Its prime factorization is 3 × 41, and it has 4 divisors: 1, 3, 41, 123.
The nearest primes are 113 (below) and 127 (above).
Numbers around 123
| Number | Prime? | Factorization |
|---|---|---|
| 118 | Composite | 2 × 59 |
| 119 | Composite | 7 × 17 |
| 120 | Composite | 2³ × 3 × 5 |
| 121 | Composite | 11² |
| 122 | Composite | 2 × 61 |
| 123 | Composite | 3 × 41 |
| 124 | Composite | 2² × 31 |
| 125 | Composite | 5³ |
| 126 | Composite | 2 × 3² × 7 |
| 127 | Prime | 127 |
| 128 | Composite | 2⁷ |
Check another number
Any whole number up to 24 digits. Commas are fine.
Try 1,000,003 or 561. Want a list instead? See the list of prime numbers.
Is 127 prime?
Yes, prime
Number of divisors
2
Previous prime
113
Next prime
131
Divisors: 1, 127
Its only divisors are 1 and 127, so it's prime.
See where 123 sits among the first hundred numbers on the prime numbers chart, or browse every number from 1 to 1,000.
Questions people ask
Is 123 a prime number?
No, 123 is not a prime number. It's composite.
What are the factors of 123?
4 factors: 1, 3, 41, 123.
Is 123 prime or composite?
Composite: 123 = 3 × 41.