Skip to content

GCF Calculator

Find the Greatest Common Factor (GCF), LCM, or simplified ratio of any list of integers.

Numbers

Updates as you type
What to solve for ?

Greatest Common Factor — the largest integer that divides every input evenly.

Quick examples (click to load)
Numbers ?
1
2

Method 1 — Factor ladder

Divide by shared primes until no prime divides all inputs
Set numbers above to see the ladder.

Multiply the divisors on the left to get the GCF. The bottom row shows what remains (mutually coprime).

Method 2 — Euclidean algorithm

GCF(a, b) = GCF(b, a mod b), repeat until remainder is 0
  1. Set numbers above to see the running pairwise calculation.

Verification

Each input should be an exact multiple of the GCF
  • Set numbers above to see the verification.

Formula

GCF(a, b) = GCF(b, a mod b)
GCF
Greatest common factor (also called HCF, GCD) — the largest integer that divides every input evenly.
LCM
Least common multiple — the smallest positive integer every input divides into. For two numbers: LCM = |a × b| / GCF.
Coprime
A set whose GCF is 1. No prime divides every input, so the ratio is already in lowest terms.
Euclidean algorithm — your numbers
  1. Inputs:
  2. Shared prime factors:
  3. Simplified ratio:
  4. GCF =

For more than two numbers, apply the identity pairwise: GCF(a, b, c) = GCF(GCF(a, b), c). The factor-ladder view above runs this in parallel — every step divides the whole row by a single shared prime.