GCD GCD / HCF Calculator

GCD / HCF Result

What is GCD / HCF?

The Greatest Common Divisor (GCD), also known as Highest Common Factor (HCF), is the largest number that divides two or more integers without leaving a remainder.

GCD(48, 18) = 6
Because 6 is the largest number that divides both 48 and 18 evenly.

Euclidean Algorithm

The most efficient method to find GCD uses the Euclidean algorithm:

  1. Divide the larger number by the smaller number.
  2. Replace the larger number with the remainder.
  3. Repeat until remainder is 0.
  4. The last non-zero remainder is the GCD.
GCD(48, 18): 48 = 18×2 + 12 → 18 = 12×1 + 6 → 12 = 6×2 + 0 → GCD = 6

Frequently Asked Questions

What is the GCD of 12 and 18?
GCD(12, 18) = 6. The common factors of 12 and 18 are 1, 2, 3, and 6. The greatest is 6.
What is the difference between GCD and HCF?
GCD (Greatest Common Divisor) and HCF (Highest Common Factor) are different names for the exact same concept. They are identical.
What is GCD used for?
GCD is used to simplify fractions (divide both numerator and denominator by GCD), find LCM, solve linear Diophantine equations, and in cryptography algorithms like RSA.