Skip to content
CalcPilot
Salary calculator: gross to net pay for Canada, the US, the UK, France and Germany
Math

LCM Calculator

Find the least common multiple of two or more numbers.

LCM = smallest number divisible by every input
1
2

Try an example

Least common multiple

36

About this calculator

What Is the Least Common Multiple (LCM)?

The least common multiple of two or more whole numbers is the smallest positive number that every one of them divides into evenly. It is written LCM(a, b). The multiples of 4 are 4, 8, 12, 16… and the multiples of 6 are 6, 12, 18…, so the first one they share is 12, and LCM(4, 6) = 12. Enter a list of numbers separated by commas in this LCM calculator and it finds the answer for any count of values.

Three Ways to Find the LCM

1. List the multiples. Write out multiples of each number until one appears in every list. It works for small numbers but gets tedious fast — finding LCM(18, 26) this way means writing a long list.

2. Use prime factorization. Break each number into primes, then multiply the highest power of every prime that appears. For 12 = 2² × 3 and 18 = 2 × 3², the LCM is 2² × 3² = 36.

3. Use the greatest common factor. For two numbers, LCM(a, b) = (a × b) ÷ GCF(a, b). With 12 and 18 the GCF is 6, so the LCM is 12 × 18 ÷ 6 = 36. For more than two numbers, find the LCM of the first pair, then the LCM of that result with the next number, and so on.

Worked Example

The LCM of 15 and 20 is 60 — the smallest number both 15 and 20 divide into with no remainder.

Why the LCM Matters

  • Adding and subtracting fractions: the LCM of the denominators is the least common denominator, which keeps numbers small. See the Fraction Calculator.
  • Scheduling: if one event repeats every 4 days and another every 6, they coincide every 12 days.
  • Gears and cycles: engineers use the LCM to know when repeating patterns line up again.

LCM and GCF Work Together

The LCM looks upward at shared multiples, while the greatest common factor looks downward at shared divisors. Knowing one gives you the other for any pair of numbers, through the formula above. Try the GCF Calculator for the matching side of the problem.

Worked example

The least common multiple of 12 and 18 is 36 — the smallest number both 12 and 18 divide into evenly.

Frequently asked questions

How is the LCM calculated?

This calculator uses the relationship LCM(a, b) = (a × b) ÷ GCF(a, b), extended pairwise across every number you enter.

What's the LCM used for?

Most commonly for adding or comparing fractions with different denominators — the LCM of the denominators gives the smallest common denominator to convert them to.

Can I find the LCM of more than two numbers?

Yes — add as many numbers as you need; the calculator finds the LCM pairwise across the whole list.

What's the difference between LCM and GCF?

LCM is the smallest number every input divides into; GCF (greatest common factor) is the largest number that divides every input evenly — opposite ends of the same relationship.

More Math calculators

Advertise on CalcPilot