The greatest common factor (GCF, also called GCD or HCF) is the largest number that divides all of your numbers exactly. The least common multiple (LCM) is the smallest number they all divide into. Both are used to simplify fractions and find common denominators.
Formula
LCM(a, b) = |a × b| ÷ GCF(a, b)
The GCF is found with Euclid’s algorithm: repeatedly replace the larger number with the remainder of dividing it by the smaller, until the remainder is 0. For more than two numbers, apply the rule to them one pair at a time.
Worked example
GCF(12, 18, 30) = 6, because 6 is the largest number that divides all three. LCM(12, 18, 30) = 180, the smallest number all three divide into.
Frequently asked questions
How do I find the GCF of two numbers?
List the factors of each and pick the largest shared one, or use Euclid’s algorithm: GCF(48, 18) → GCF(18, 12) → GCF(12, 6) → 6.
What is the LCM used for?
Adding fractions: the LCM of the denominators is the lowest common denominator. For 1/4 + 1/6, LCM(4, 6) = 12.
Last updated · Calculations checked by automated tests· Editorial policy