About the GCD / HCF Calculator
Find the greatest common divisor (GCD), also called the highest common factor (HCF) or GCF, with Euclidean algorithm steps.
Also known as: hcf calculator, greatest common divisor, highest common factor, gcf calculator, greatest common factor, gcd calculator.
How to use this calculator
- Enter whole numbers.
- The result updates instantly as you type — press Calculate (or Enter) at any time.
- Open “Step-by-step” to see how the answer was worked out.
- Use Copy result or Share to save the answer or send a link with your inputs.
Formula
Euclid: GCD(a, b) = GCD(b, a mod b), GCD(a, 0) = a
Worked example
Using the values pre-filled in the calculator above:
- Whole numbers: 48, 180
the calculator returns:
- GCD (HCF): 12
- LCM of first two: 720
Working
48 = 0 × 180 + 48180 = 3 × 48 + 3648 = 1 × 36 + 1236 = 3 × 12 + 0GCD = 12