🧮

LCM & GCD Calculator

Free LCM and GCD (HCF) calculator — least common multiple and greatest common divisor of two or more whole numbers.

Loading…

Everyday Uses

Fractions homework

Find a common denominator (LCM) or simplify fractions (GCD) fast.

Repeating schedules

Work out when two cycles line up again using the LCM.

Equal groups

Split items into the largest equal groups with the GCD.

Number theory

Explore factors and multiples of any list of whole numbers.

Frequently Asked Questions

What is the difference between LCM and GCD?

The GCD (greatest common divisor, also called HCF, highest common factor) is the largest number that divides all your numbers exactly. The LCM (least common multiple) is the smallest number that all of them divide into. For 12 and 18, the GCD is 6 and the LCM is 36.

How do you find the GCD and LCM?

The fastest way to find the GCD is the Euclidean algorithm: divide the larger number by the smaller and replace it with the remainder, repeating until the remainder is zero. Then the LCM comes from the identity GCD × LCM = product of the two numbers, so LCM = (a × b) ÷ GCD. This calculator chains that across a whole list.

What are LCM and GCD used for?

The LCM is used to find a common denominator when adding or subtracting fractions, and to work out when repeating events line up. The GCD is used to simplify fractions to lowest terms and to split things into the largest equal groups.