🧰 ToolPicoAll Tools →
HomeBlog › GCF and LCM: How to Find Them Without Guessing

GCF and LCM: How to Find Them Without Guessing (With Real Examples)

Whether you're simplifying a fraction, splitting a group into even batches, or figuring out when two repeating schedules will next line up, it comes down to two numbers: the GCF and the LCM. Here's how to actually find them by hand — and which method to reach for depending on the numbers you've got.

In this guide

GCF vs. LCM: what each one actually means

Quick answerThe GCF (greatest common factor, also called the GCD, greatest common divisor) is the largest number that divides every one of your numbers with no remainder. The LCM (least common multiple) is the smallest number that every one of your numbers divides into evenly. For 12 and 18: GCF = 6, LCM = 36.

It helps to think of them as opposite directions. GCF looks down — it finds the biggest shared piece two or more numbers can be broken into. LCM looks up — it finds the smallest number both numbers fit into cleanly. You'll use GCF whenever you're trying to shrink or simplify something (a fraction, a group size); you'll use LCM whenever you're trying to combine or synchronize something (denominators, repeating schedules).

GCF vs. GCDThere's no mathematical difference between the two terms. "GCF" is what most US school textbooks call it; "GCD" is the term used in computer science and higher math. Same number, same method, different name.

Finding the GCF and LCM with prime factorization

Quick answerBreak each number into prime factors. For the GCF, multiply the primes the numbers share, using the lowest power each appears with. For the LCM, multiply every prime factor that shows up in any number, using its highest power.

Take 12 and 18. Written as prime factors, 12 = 2² × 3 and 18 = 2 × 3². Both numbers share the primes 2 and 3. Using the lowest power of each shared prime (2¹ and 3¹) gives 2 × 3 = 6 — that's the GCF. For the LCM, take the highest power of every prime that appears anywhere: 2² and 3² gives 4 × 9 = 36.

Worked example: 12 and 18
NumberPrime factorization
122² × 3
182 × 3²
GCF (lowest shared powers)2 × 3 = 6
LCM (highest powers overall)2² × 3² = 36

This method scales fine to three or more numbers too — you just keep every prime that's common to all of them for the GCF, and every prime that appears in any of them for the LCM. For 24, 36, and 48, that works out to a GCF of 12 and an LCM of 144. If listing multiples is easier for you to picture, you can also find the LCM by writing out each number's multiples (4, 8, 12, 16... and 6, 12, 18, 24...) until one shows up in both lists — for 4 and 6, that's 12.

Handy shortcut for two numbers: LCM = (Number1 × Number2) ÷ GCF. Once you know the GCF of 12 and 18 is 6, you can get the LCM instantly: (12 × 18) ÷ 6 = 36, without factoring anything twice.

The Euclidean algorithm (faster for big numbers)

Quick answerDivide the larger number by the smaller one and keep the remainder. Replace the divisor with that remainder and repeat. When the remainder hits zero, the last divisor is the GCF — no prime factoring needed.

Prime factorization works well for small, friendly numbers, but it gets slow once a number's prime factors are large or unknown. The Euclidean algorithm sidesteps that entirely. For example, to find the GCF of 270 and 192: 270 = 192 × 1 + 78, then 192 = 78 × 2 + 36, then 78 = 36 × 2 + 6, then 36 = 6 × 6 + 0. The remainder just hit zero, so the GCF is 6 — reached in four quick division steps instead of factoring two three-digit numbers into primes.

This is also the method computers use under the hood, since it only needs basic division and stays fast no matter how large the numbers get. Once you have the GCF this way, the shortcut above (multiply the two numbers, divide by the GCF) gets you the LCM immediately.

Where GCF and LCM actually show up

These aren't just classroom exercises — they solve two very ordinary problems:

  • Simplifying fractions: to reduce 24/36 to lowest terms, find the GCF of 24 and 36 (which is 12) and divide both number and denominator by it, giving 2/3.
  • Splitting into equal groups: if you have 24 pencils and 36 erasers and want the largest possible number of identical goodie bags with no items left over, the GCF (12) tells you how many bags you can make.
  • Adding fractions with different denominators: to add 1/12 and 1/18, you need a common denominator — the LCM of 12 and 18, which is 36.
  • Sync / cadence problems: if one event repeats every 12 days and another every 18 days, the LCM (36) tells you how many days until they land on the same day again. As a hypothetical example only: two buses starting together, one on a 12-minute loop and one on an 18-minute loop, would next arrive at the same stop together after 36 minutes.

One more useful fact: for exactly two numbers, GCF × LCM always equals the product of the two numbers (GCF(12,18) × LCM(12,18) = 6 × 36 = 216 = 12 × 18). It's a quick way to double-check your work — though it only holds for pairs, not for three or more numbers at once.

Skip the manual factoring — enter 2 to 6 numbers and get the GCF, LCM, and all four solving methods worked out instantly.

Try the free GCF & LCM Calculator →

Frequently asked questions

How do you find the GCF of two or more numbers?
Answer: Break each number into its prime factors, then multiply the common prime factors using their lowest powers. For example, 12 = 2² × 3 and 18 = 2 × 3² share the primes 2 and 3; using the lowest powers gives 2¹ × 3¹ = 6. You can also use the Euclidean algorithm: divide the larger number by the smaller one repeatedly until the remainder is zero — the last divisor is the GCF.
How do you calculate the LCM?
Answer: Multiply all the prime factors that appear in any of the numbers, using each factor's highest power. For example, 12 = 2² × 3 and 18 = 2 × 3² give LCM = 2² × 3² = 36. For two numbers there's a shortcut: LCM = (Number1 × Number2) / GCF.
What's the difference between GCD and GCF?
Answer: There's no mathematical difference — they're two names for the same thing. GCF (greatest common factor) is the term used in most US school math; GCD (greatest common divisor) is the same concept, more commonly used in computer science and higher mathematics. Both describe the largest number that divides all the given numbers evenly.
Why does the Euclidean algorithm work faster than prime factorization?
Answer: Prime factorization requires finding every prime factor of every number, which gets slow for large numbers with big prime factors. The Euclidean algorithm only needs repeated division with remainder — a handful of steps regardless of how large the numbers are — so it's the method computers actually use.
What is the relationship between the GCF and the LCM?
Answer: For two numbers, GCF × LCM equals the product of the two numbers: GCF(a,b) × LCM(a,b) = a × b. For example, for 12 and 18: GCF = 6, LCM = 36, and 6 × 36 = 216 = 12 × 18. This relationship holds only for two numbers, not for three or more.

Related guides

A note on this guide: All examples above use simple, made-up numbers chosen to illustrate the method clearly, not real-world data. This article is for general educational reference — for graded coursework, always check the specific method your class or textbook expects.