Greatest Common Factor (GCF) Calculator

Enter two or more integers separated by commas to find their Greatest Common Factor (GCF), also called the GCD.

How to Find the GCF

Method: Euclidean Algorithm

  1. Divide the larger number by the smaller number.
  2. Replace the larger number with the remainder.
  3. Repeat until the remainder is 0. The last non-zero remainder is the GCF.

Example: GCF(48, 18)

  • 48 = 2 × 18 + 12
  • 18 = 1 × 12 + 6
  • 12 = 2 × 6 + 0 → GCF = 6

GCF & LCM Relationship

GCF(a, b) × LCM(a, b) = a × b

Related Calculators

When to Use the GCF Calculator

The greatest common factor is useful any time you need to simplify fractions, divide objects into equal groups, or solve ratio problems. For example, if you have 48 apples and 18 oranges and want to divide them into identical gift baskets with no leftovers, the GCF (6) tells you that 6 baskets is the maximum. In algebra, factoring out the GCF is the first step when simplifying polynomial expressions. In cryptography, the GCF underpins the RSA algorithm via the Euclidean algorithm.

Common scenarios: reducing a fraction like 48/18 to 8/3, splitting resources evenly between groups, finding the tile size that fits a room with no cuts, and computing modular inverses in number theory.

GCF of Multiple Numbers

To find the GCF of more than two numbers, apply the Euclidean algorithm iteratively: GCF(a, b, c) = GCF(GCF(a, b), c). For example, GCF(12, 18, 24): first GCF(12, 18) = 6, then GCF(6, 24) = 6, so the answer is 6.

NumbersGCFUse case
12, 186Simplify 12/18 → 2/3
48, 36, 2412Divide 48 items into equal groups
100, 7525Simplify 100/75 → 4/3
17, 131Both prime — no common factor

Prime Factorization Method for GCF

An alternative to the Euclidean algorithm is prime factorization. Factor each number into its prime components, then take the lowest power of each shared prime. GCF(72, 180): 72 = 2³ × 3², 180 = 2² × 3² × 5. Shared primes: 2 and 3. Lowest powers: 2² and 3¹. GCF = 2² × 3 = 4 × 3 = 12. This method is more visual and helps students understand why the GCF works, though the Euclidean algorithm is faster for large numbers.

The GCF has a key relationship with the LCM: GCF(a,b) × LCM(a,b) = a × b. So once you know the GCF, you can compute LCM(72,180) = 72×180÷12 = 1080. In algebra, factoring the GCF from polynomials is the first step in simplification: 12x² + 8x = 4x(3x + 2), where GCF(12x², 8x) = 4x.

Practical Applications of the Greatest Common Factor

The greatest common factor (GCF), also called the greatest common divisor (GCD), is the largest integer that divides two or more numbers without leaving a remainder. It appears in many practical situations. Simplifying fractions requires dividing both numerator and denominator by their GCF to reach the lowest terms. Splitting a set of objects into equal groups without remainder depends on GCF: if you have 24 apples and 36 oranges and want identical mixed bags with no fruit left over, each bag should contain GCF(24, 36) = 12 pieces total, giving 2 apples and 3 oranges per bag. The Euclidean algorithm finds the GCF efficiently: repeatedly divide the larger number by the smaller and replace the larger with the remainder until the remainder reaches zero. The last non-zero remainder is the GCF. For example, GCF(48, 18): 48 = 2 times 18 + 12; 18 = 1 times 12 + 6; 12 = 2 times 6 + 0. The GCF is 6. This algorithm handles numbers of any size in a predictable number of steps.

GCF Reference Table

NumbersGCFFraction simplified
12, 18612/18 → 2/3
24, 361224/36 → 2/3
100, 752575/100 → 3/4
48, 641648/64 → 3/4
17, 131Already in lowest terms
Have Feedback or a Suggestion? Contact Us
Top