GCD/LCM Calculator

Calculate Greatest Common Divisor and Least Common Multiple of numbers.

Helpful?
Enter Numbers
1
2
Formulas
GCD (Greatest Common Divisor)

The largest number that divides all given numbers without remainder.

GCD(a, b) = GCD(b, a mod b)
LCM (Least Common Multiple)

The smallest positive number divisible by all given numbers.

LCM(a, b) = (a × b) / GCD(a, b)
GCD
12
Greatest Common Divisor
LCM
72
Least Common Multiple
Relationship Verification
24 × 36 = 12 × 72 = 864
a × b = GCD × LCM
Prime Factorization
Step-by-Step (Euclidean Algorithm)
Common Divisors
First Multiples of LCM
Share this tool