GCD & LCM Calculator

Calculate the greatest common divisor and least common multiple of two or more numbers with steps shown.

1,157 views

How Are GCD and LCM Calculated?

The greatest common divisor (GCD) is the largest number that divides all the given numbers; it is computed efficiently with the Euclidean algorithm (repeatedly replacing the larger number with the remainder of the division). The least common multiple (LCM) is the smallest number divisible by all inputs, obtained from LCM(a,b) = a × b ÷ GCD(a,b).

Enter two or more numbers separated by commas — the tool reduces them pairwise and shows both results instantly. Useful for simplifying fractions (GCD) and finding common denominators or repeating schedules (LCM).

Frequently Asked Questions

What are GCD and LCM used for?

GCD simplifies fractions (divide numerator and denominator by it) and splits things into equal largest groups. LCM finds common denominators and answers "when do two repeating events coincide" questions.

Can I enter more than two numbers?

Yes. Separate them with commas — e.g. 12, 18, 24. The tool reduces the whole list: GCD(12,18,24) = 6 and LCM(12,18,24) = 72.

What if the numbers share no common factor?

Then the GCD is 1 (the numbers are coprime) and the LCM is simply their product divided by nothing extra — e.g. GCD(8,9) = 1, LCM(8,9) = 72.

Similar Tools