Find LCM and GCD of any set of numbers.
🔢 GCD = largest number dividing all inputs. LCM = smallest number divisible by all inputs.
This calculator finds the GCD (greatest common divisor) and LCM (least common multiple) of any set of positive integers. These are fundamental concepts in number theory with practical uses in math and programming.
For any two numbers: GCD(a,b) × LCM(a,b) = a × b. So if you know one, you can find the other instantly. This calculator uses the efficient Euclidean algorithm, which works even for very large numbers.
The LCM & GCD Calculator lets you figure out lcm calculatorinstantly, without reaching for a spreadsheet or doing the math by hand. Whether you're planning a budget, checking a loan, or working through homework, the tool applies the correct formula behind the scenes and shows the result the moment you enter your numbers.
Unlike a static chart or table, this calculator adapts to your exact inputs. You can adjust any value and see the outcome update in real time, which makes it easy to compare scenarios — for example, "what if the rate were 1% lower?" or "what if I paid an extra $50 a month?"
Common uses: people reach for this tool when they need to find a lcm of three numbers calculator, gcd of any set of numbers, least common multiple calculator, or greatest common divisor finder.
Browser-based tools like this one have a few real advantages over installed software or manual methods:
The LCM & GCD Calculator is based on the following formula:
GCD via Euclid LCM(a, b) = (a × b) / GCD(a, b)
Variables: GCD(a, b) = Greatest common divisor LCM(a, b) = Least common multiple a, b = Positive integers
The GCD is found by repeated remainder (Euclid's algorithm). The LCM follows from the identity linking the two — multiplying the numbers and dividing by their GCD.
Worked example: Step 1: Euclid for GCD(12, 18): 18 mod 12 = 6; 12 mod 6 = 0, so GCD = 6. Step 2: a × b = 12 × 18 = 216. Step 3: LCM = 216 / 6 = 36. Result: GCD(12, 18) = 6 and LCM(12, 18) = 36.
More tools you might find useful