CalcDuck

Factor Calculator

Factor Calculator

A positive whole number, up to 1,000,000,000,000 (1e12).
All factors
1, 2, 3, 4, 5, 6, 10, 12, 15, 20, 30, 60
Number of factors
12
Sum of all factors
168
Is it prime?
No
Is it a perfect number?
No
Factor pairs
FactorPaired factor
160
230
320
415
512
610

The factors of a number are every whole number that divides it with no remainder. The number 28 has six factors — 1, 2, 4, 7, 14 and 28 — which sum to 56, exactly twice 28, making 28 a perfect number. A number with exactly two factors, 1 and itself, is prime; 28 is not prime because it has more than two.

Tip: “Copy with settings” shares a link that opens this calculator with your numbers already filled in.

How this calculator works

This calculator lists every positive factor (divisor) of a whole number, pairs them up so you can see which two factors multiply together to give the original number, and reports the total count and sum of all factors. It also flags two special properties: whether the number is prime (exactly two factors) and whether it is a perfect number (its factors, excluding itself, add up to the number itself).

This is different from prime factorization, which breaks a single number down into the prime numbers that multiply together to build it (for example 28 = 2² × 7). This calculator instead lists all of the divisors of one number — use the GCF and LCM calculator if you want prime factorizations of two or more numbers to find their greatest common factor or least common multiple.

How factors are found

A number d is a factor of n when n ÷ d leaves no remainder (n mod d = 0).Factors always come in pairs (d, n ÷ d) that multiply to n, found efficiently by checking every d up to √n.Sum of all factors (including n itself) compares to 2n: less than 2n means n is deficient, exactly 2n means n is perfect, more than 2n means n is abundant (the Euclid–Euler theorem links every even perfect number to a Mersenne prime).

This calculator checks every candidate divisor from 1 up to the square root of the number, which is enough to find every factor pair without checking every number up to n itself.

Worked example: the factors of 28

  1. Check every whole number from 1 up to √28 ≈ 5.3, so 1, 2, 3, 4 and 5.
  2. 28 ÷ 1 = 28, 28 ÷ 2 = 14, 28 ÷ 4 = 7 all divide evenly (3 and 5 do not), giving the pairs (1, 28), (2, 14) and (4, 7).
  3. Collecting every number from those pairs gives the six factors: 1, 2, 4, 7, 14, 28.
  4. Adding them up: 1 + 2 + 4 + 7 + 14 + 28 = 56, which is exactly 2 × 28 — so 28 is a perfect number, and since it has more than two factors it is not prime.

Frequently asked questions

What is the difference between a factor and a prime factor?

A factor is any whole number that divides another evenly (28 has six factors). A prime factor is a factor that is also a prime number (28's prime factors are just 2 and 7 — the building blocks that multiply together, with repetition, to recreate 28 as 2 × 2 × 7).

What makes a number a perfect number?

A perfect number equals the sum of its proper divisors (all its factors except itself). The first few are 6 (1+2+3), 28 (1+2+4+7+14), 496 and 8,128. Every even perfect number found so far corresponds to a Mersenne prime, a pattern known since Euclid.

Why is 1 not considered a prime number?

A prime number is defined as having exactly two distinct positive factors: 1 and itself. The number 1 has only one factor (itself), so it fails that definition and is classified separately as a unit, not a prime.

How large a number can this calculator handle?

Up to 1,000,000,000,000 (10¹²). Beyond that, checking every candidate divisor up to the square root becomes too slow to do instantly in a browser, so the calculator shows a message instead of an incomplete result.

Do negative numbers have factors?

Every positive factor of a number also has a negative counterpart (both 4 and −4 divide 28), but by convention factor lists — including this calculator's — show only the positive factors.

Sources

Related calculators