Home › Mathematics Calculators › GCD and LCM Calculator
Find the greatest common divisor and least common multiple of two whole numbers.
How the calculation works
The calculator uses the Euclidean algorithm to find the GCD, then uses it to compute the LCM.
Formula used
LCM(a, b) = a × b ÷ GCD(a, b)
Example
For 12 and 18 the GCD is 6 and the LCM is 36.
Frequently asked questions
Where is GCD used?
Simplifying fractions and splitting items into equal groups.
Can I use decimals?
No. Enter whole numbers only.
Related calculators
Results are estimates for general information only and are not professional financial, medical or legal advice.