GCF & LCM Calculator
Find the Greatest Common Factor (GCF) and Least Common Multiple (LCM) of two or more integers.
GCF & LCM formulas
Worked examples
Find the GCF and LCM of 48 and 180.
- 48 = 24 × 3, 180 = 22 × 32 × 5
- GCF = 22 × 3 = 12
- LCM = 24 × 32 × 5 = 720 (check: 48 × 180 ÷ 12 = 720)
Answer: GCF = 12, LCM = 720
Euclidean algorithm for GCF(180, 48).
- 180 = 3 × 48 + 36
- 48 = 1 × 36 + 12
- 36 = 3 × 12 + 0 → stop
Answer: GCF = 12
Buses leave every 12 and 18 minutes. When do they next leave together?
- LCM(12, 18) = 36
Answer: In 36 minutes
Tips & common mistakes
- GCF simplifies fractions; LCM finds common denominators.
GCF vs LCM in plain English
The greatest common factor (GCF) — also called the greatest common divisor (GCD) or highest common factor (HCF) — is the largest number that divides into all of your numbers evenly. The least common multiple (LCM) is the smallest number that all of your numbers divide into.
Three ways to find them
- List the factors (good for small numbers): factors of 12 are 1, 2, 3, 4, 6, 12 and of 18 are 1, 2, 3, 6, 9, 18 — the biggest shared one is 6.
- Prime factorization: 48 = 24 × 3 and 180 = 22 × 32 × 5. The GCF takes each shared prime at its lowest power: 22 × 3 = 12. The LCM takes every prime at its highest power: 24 × 32 × 5 = 720.
- Euclid’s algorithm (fastest for big numbers): replace the larger number by the remainder of dividing it by the smaller, until the remainder is 0. 180 ÷ 48 leaves 36; 48 ÷ 36 leaves 12; 36 ÷ 12 leaves 0 — so the GCF is 12.
Shortcut for two numbers: LCM(a, b) = a × b ÷ GCF(a, b). For 48 and 180: 8,640 ÷ 12 = 720.
Where you actually use them
- GCF — simplifying fractions (48/180 ÷ 12 = 4/15), splitting things into equal groups, tiling a floor with the largest square tile.
- LCM — adding fractions (common denominator), finding when repeating events line up again (buses every 12 and 18 minutes meet every 36 minutes).
GCF and LCM of common number pairs
| Numbers | GCF | LCM |
|---|---|---|
| 8 and 12 | 4 | 24 |
| 12 and 18 | 6 | 36 |
| 15 and 25 | 5 | 75 |
| 16 and 24 | 8 | 48 |
| 18 and 24 | 6 | 72 |
| 20 and 30 | 10 | 60 |
| 24 and 36 | 12 | 72 |
| 27 and 36 | 9 | 108 |
| 36 and 48 | 12 | 144 |
| 42 and 56 | 14 | 168 |
| 48 and 180 | 12 | 720 |
| 60 and 72 | 12 | 360 |
Frequently asked questions
What is the GCF of 12 and 18?
The GCF of 12 and 18 is 6. The factors of 12 are 1, 2, 3, 4, 6, 12 and the factors of 18 are 1, 2, 3, 6, 9, 18; the largest one they share is 6.
Is GCF the same as GCD and HCF?
Yes. Greatest common factor (GCF), greatest common divisor (GCD) and highest common factor (HCF) are three names for the same thing.
How do you find the LCM from the GCF?
For two numbers, LCM = (a × b) ÷ GCF. For example, the GCF of 48 and 180 is 12, so the LCM is 48 × 180 ÷ 12 = 720.
What is the GCF of two prime numbers?
The GCF of two different prime numbers is always 1, and their LCM is simply their product. Numbers whose GCF is 1 are called relatively prime or coprime.
Can the GCF be larger than the smallest number?
No. The GCF can be at most the smallest number, and it equals the smallest number only when that number divides all the others.
How do you find the GCF of three or more numbers?
Find the GCF of the first two, then the GCF of that result with the next number, and so on. For 24, 36 and 60: GCF(24, 36) = 12, then GCF(12, 60) = 12.