🧮 Math Tools

LCM & GCD Calculator

Calculate the Lowest Common Multiple and Greatest Common Divisor for up to 10 numbers. Shows step-by-step prime factorization, Euclidean algorithm and real-world applications.

Up to 10 numbers at once Step-by-step working shown Prime factorization method Fraction simplifier
AdSense — 728×90 Leaderboard

LCM and GCD Calculator

Enter 2–10 whole numbers. The LCM is the smallest number that all inputs divide into evenly.

Enter 2–10 whole numbers. The GCD (also called HCF) is the largest number that divides all inputs without a remainder.

Enter a fraction to reduce it to its simplest form. Uses GCD to divide both numerator and denominator.

Numerator
/
Denominator
AdSense — 728×90 Leaderboard
✂️
Need a full fraction calculator?
The free Fraction Calculator handles addition, subtraction, multiplication and division of fractions — with step-by-step working and mixed number support.
Fraction Calculator →
⭐ Ratings

Rate this tool

4.8
★★★★★
Based on 21,344 ratings
5
18,783
4
1,494
3
640
2
213
1
214
Was this calculator helpful?
Thank you!
Features

Step-by-step working, real-world context and fraction simplifier — what most tools skip

Most LCM and GCD calculators return a number and nothing else. This tool shows the full prime factorization method for LCM, the Euclidean algorithm for GCD, a real-world application explanation for every result, and a built-in fraction simplifier.

Up to 10 numbers
Add or remove numbers dynamically. Most free tools only handle two at a time. This tool computes LCM and GCD across the full set simultaneously using iterative reduction.
Prime factorization method
A factor table shows the prime factorization of every input. For LCM, it highlights which factors are used and why. For GCD, it shows which factors appear in all numbers. Invaluable for understanding the answer, not just reading it.
Euclidean algorithm for GCD
The step-by-step Euclidean algorithm — the most efficient method for GCD — is shown in full. Each division step is listed so the process is completely transparent.
Real-world application
Every result includes a plain-English real-world explanation. LCM: “Two events that repeat every X and Y days will next coincide in Z days.” GCD: “The largest equal group size that can be made from X and Y items with no remainder.” Absent from all competitor tools.
Fraction simplifier
The third tab simplifies any fraction to its lowest terms using GCD. Shows the GCD used, the division step, and whether the fraction is already fully reduced. Direct connection between the math concept and its practical application.
Copy results instantly
Click the result card to copy the LCM or GCD value to your clipboard. Quick access for pasting into homework, spreadsheets or code.
How to use

How to calculate LCM and GCD

1
Choose LCM or GCD mode
Click the LCM Calculator tab for lowest common multiple, or the GCD / HCF Calculator tab for greatest common divisor. The Fraction Simplifier tab uses GCD to reduce fractions automatically.
2
Enter your numbers
Type whole numbers into the input fields. Click “Add number” to add more inputs (up to 10). All inputs must be positive whole numbers. Decimals and negative numbers are not supported for LCM/GCD.
3
Click Calculate
The result appears in the large card. Below it, the step-by-step working shows the prime factorization table and the method used. Read through each step to understand how the answer was reached.
4
Read the real-world application
The application card translates the result into a practical scenario — scheduling problems for LCM, equal grouping problems for GCD. This helps contextualise the abstract result and spot errors in problem setup.
Comparison

LazyTools vs other LCM & GCD calculators

Most free LCM and GCD tools return a number with no context. Step-by-step prime factorization, Euclidean algorithm display, real-world application explanation and a built-in fraction simplifier together are absent from all major free tools.

Feature⭐ LazyTools calculatorsoup.commathwarehouse.comomnicalculator.com
LCM and GCD calculation
Up to 10 numbers⚠ 2 only
Step-by-step prime factorization⚠ Partial
Euclidean algorithm display
Real-world application
Fraction simplifier built in⚠ Separate⚠ Separate
No ads / no signup⚠ Ads⚠ Ads⚠ Ads
Quick reference

LCM and GCD of common number pairs

NumbersGCD / HCFLCMLCM x GCDProduct (a x b)
4 and 62122424
12 and 18636216216
8 and 124249696
15 and 20560300300
7 and 131919191
24 and 361272864864
9 and 12336108108
100 and 752530075007500

Key formulas and identities

PropertyFormula / RuleExample
LCM-GCD relationshipLCM(a,b) x GCD(a,b) = a x bLCM(4,6) x GCD(4,6) = 12 x 2 = 24 = 4 x 6
Coprime numbersGCD = 1, so LCM = a x bGCD(7,13) = 1, LCM = 91
One divides the otherGCD = smaller, LCM = largerGCD(4,12) = 4, LCM = 12
Equal numbersGCD = LCM = the numberGCD(6,6) = 6, LCM(6,6) = 6
GCD with 1GCD(n,1) = 1 alwaysGCD(100,1) = 1
LCM with 1LCM(n,1) = n alwaysLCM(100,1) = 100
Complete guide

LCM & GCD Calculator — Lowest Common Multiple and Greatest Common Divisor Explained

The Lowest Common Multiple (LCM) and Greatest Common Divisor (GCD) are two of the most fundamental concepts in number theory. They appear in primary school arithmetic, university mathematics and practical programming tasks. Understanding them deeply — not just knowing how to calculate them — unlocks a wide range of problem-solving approaches in scheduling, cryptography, signal processing and computer science.

LCM and GCD calculator for multiple numbers free

The LCM of a set of numbers is the smallest positive integer that is divisible by every number in the set. For two numbers, it can be calculated as LCM(a,b) = (a x b) / GCD(a,b). For more than two numbers, apply the formula iteratively: LCM(a,b,c) = LCM(LCM(a,b), c). The GCD of a set of numbers is the largest positive integer that divides all numbers in the set without remainder. Also called HCF (Highest Common Factor) in UK and Commonwealth curricula. For more than two numbers: GCD(a,b,c) = GCD(GCD(a,b), c).

Lowest common multiple with step-by-step prime factorization

The prime factorization method for LCM: factorise each number into its prime factors. For each distinct prime, take the highest power of that prime that appears across all factorisations. Multiply these together. For example, LCM(12, 18): 12 = 2^2 x 3, 18 = 2 x 3^2. Take 2^2 (highest power of 2) and 3^2 (highest power of 3): LCM = 4 x 9 = 36. This method shows exactly why each prime is included and which input contributed the highest power — making it far more instructive than a black-box calculation.

GCD calculator using Euclidean algorithm online

The Euclidean algorithm is the most efficient method for finding GCD, dating back to ancient Greece. The algorithm is: GCD(a,b) = GCD(b, a mod b), repeated until the remainder is 0. At that point the divisor is the GCD. Example: GCD(48, 18). Step 1: 48 = 2 x 18 + 12. Step 2: 18 = 1 x 12 + 6. Step 3: 12 = 2 x 6 + 0. Remainder is 0, so GCD = 6. The algorithm is used in RSA encryption key generation, continued fraction computation and numerous computer science algorithms.

LCM for scheduling calculator

The most practical real-world use of LCM is solving scheduling problems. If event A repeats every 4 days and event B repeats every 6 days, when will they next coincide? The answer is LCM(4,6) = 12 days. If a factory produces batches every 8 hours and another every 12 hours, LCM(8,12) = 24 hours for synchronisation. If two gears have 15 and 20 teeth respectively, LCM(15,20) = 60 — meaning after 60 gear teeth of travel, the same pair of teeth will mesh again. LCM is also used to find common denominators when adding fractions: to add 1/4 + 1/6, the common denominator is LCM(4,6) = 12.

Fraction simplifier using GCD

To simplify a fraction to lowest terms, divide both numerator and denominator by their GCD. Example: 12/18. GCD(12,18) = 6. 12/6 = 2, 18/6 = 3. Simplified fraction: 2/3. The fraction is in lowest terms when GCD(numerator, denominator) = 1 — i.e. the numerator and denominator are coprime. This is the basis of all fraction arithmetic: to add or subtract fractions, find the LCM of the denominators; to simplify the result, divide by the GCD.

Common denominator calculator

The least common denominator (LCD) of two or more fractions is the LCM of their denominators. It is the smallest number that all denominators divide into evenly. To add 1/4 + 1/6 + 1/9: LCM(4,6,9) = 36. Convert each fraction: 9/36 + 6/36 + 4/36 = 19/36. Using the LCM rather than just multiplying all denominators together gives the smallest possible denominator, keeping the arithmetic simpler.

Frequently asked questions

The GCD (Greatest Common Divisor) is the largest number that divides all the inputs without a remainder. The LCM (Lowest Common Multiple) is the smallest number that all inputs divide into without a remainder. For any two numbers a and b: LCM(a,b) x GCD(a,b) = a x b. GCD deals with factors (what the numbers are made of); LCM deals with multiples (what numbers the inputs create together).
Yes — HCF (Highest Common Factor) and GCD (Greatest Common Divisor) are exactly the same thing, just different names used in different education systems. HCF is the term commonly used in UK, India and Commonwealth curricula. GCD is used more widely in US curricula and mathematics generally. Both refer to the largest number that divides all inputs exactly.
No. The LCM is always greater than or equal to the largest input. It equals the largest input only when the largest input is divisible by all others — for example, LCM(4,12) = 12 because 12 is divisible by 4. Otherwise LCM is strictly larger than all inputs. The LCM can never be smaller than any single input because every input must divide the LCM exactly.
LCM has many practical applications: finding the earliest time two cyclic events will coincide (buses, shift schedules, machine cycles); finding the lowest common denominator for adding fractions; synchronising repeating patterns in music and tiling; computer science for memory alignment and timing calculations; gear tooth calculations in engineering. The scheduling use is the most intuitive: if event A repeats every 4 days and event B every 6 days, LCM(4,6) = 12 tells you they next coincide in 12 days.
Always 1. Prime numbers have no factors other than 1 and themselves. Two different primes share no common factors other than 1, so their GCD is always 1. Numbers whose GCD is 1 are called coprime or relatively prime. For example, GCD(7,13) = 1, even though 7 and 13 are not small numbers. When two numbers are coprime, LCM(a,b) = a x b.
The Euclidean algorithm finds GCD by repeatedly taking the remainder of division. GCD(a,b) = GCD(b, a mod b). Keep replacing (a,b) with (b, remainder) until the remainder is 0. The last non-zero remainder is the GCD. For GCD(48,18): 48 mod 18 = 12, then 18 mod 12 = 6, then 12 mod 6 = 0. GCD = 6. The algorithm works because GCD(a,b) = GCD(b,r) where r = a mod b — any common divisor of a and b must also divide r.
To add fractions with different denominators, find the LCM of the denominators (the Least Common Denominator). Convert each fraction so it has that denominator, then add the numerators. For 1/4 + 1/6: LCM(4,6) = 12. Convert: 3/12 + 2/12 = 5/12. Using LCM gives the smallest denominator, keeping numbers manageable. Multiplying denominators together also works but gives larger numbers: 4 x 6 = 24, giving 6/24 + 4/24 = 10/24, which simplifies to 5/12 — same answer, more steps.
For three or more numbers, apply LCM iteratively: LCM(a,b,c) = LCM(LCM(a,b), c). For example, LCM(4,6,9): LCM(4,6) = 12, then LCM(12,9) = 36. So LCM(4,6,9) = 36. Alternatively, use prime factorization: take each prime's highest power across all inputs. 4 = 2^2, 6 = 2 x 3, 9 = 3^2. Highest powers: 2^2 and 3^2. LCM = 4 x 9 = 36. Both methods give the same result.
Related tools

More free math tools