GCD & LCM Calculator

Calculate the highest common factor and lowest common multiple of any set of whole numbers, with the division steps shown.

Runs in your browser. Nothing is uploaded Free, no sign-up Works on mobile
NumbersTwo or more whole numbers, separated by commas or spaces
GCD / HCF
6
LCM
180

Euclid’s algorithm (12, 18)

12 = 18 × 0 + 12 18 = 12 × 1 + 6 12 = 6 × 2 + 0

How to use GCD & LCM Calculator

  1. Enter two or more whole numbers.
  2. Read the HCF/GCD and LCM.
  3. Follow Euclid’s algorithm steps for the first two numbers.

Frequently asked questions

What is the relation between HCF and LCM?

For two numbers, HCF × LCM = the product of the numbers. For 12 and 18: 6 × 36 = 216 = 12 × 18.

Is GCD the same as HCF?

Yes. Greatest common divisor (GCD) and highest common factor (HCF) are two names for the same thing.