Greatest Common Factor (GCF)

Calculate GCF, GCD, or HCF of two or more numbers using factorization with step-by-step work.

Calculate the Greatest Common Factor (GCF), Greatest Common Divisor (GCD), or Highest Common Factor (HCF) of two or more whole numbers with step-by-step factorization.

Separate numbers with commas or spaces
GCF
?
Max 50 characters
Try:
help_outlineHow to Useexpand_more

Finding the Greatest Common Factor

This calculator finds the GCF (also called GCD or HCF) of two or more whole numbers using factorization. Enter your numbers separated by commas or spaces and see the complete work with all factors listed.

Three Methods to Find GCF:

  1. Factorization: List all factors of each number, identify common factors, select the largest
  2. Prime Factorization: Find prime factors of each number, multiply the common prime factors
  3. Euclidean Algorithm: Repeatedly subtract smaller from larger until reaching zero

This Calculator Also Finds:

  • Greatest Common Factor (GCF)
  • Greatest Common Divisor (GCD)
  • Highest Common Factor (HCF)
infoWhat is Greatest Common Factor (GCF)?expand_more

The Greatest Common Factor (GCF) of a set of whole numbers is the largest positive integer that divides evenly into all numbers with zero remainder. It's also known as the Greatest Common Divisor (GCD) or Highest Common Factor (HCF).

For example, for the numbers 18, 30, and 42, the GCF is 6 because 6 is the largest number that divides all three evenly (18÷6=3, 30÷6=5, 42÷6=7).

Special case - GCF with zero: Any non-zero whole number k times 0 equals 0, so every non-zero integer is a factor of 0. Therefore, GCF(k, 0) = k for any whole number k. However, GCF(0, 0) is undefined.

functionsFormulaexpand_more

Method 1: Factorization

1. List all factors of each number

2. Identify factors common to all numbers

3. The greatest common factor is the largest one

Method 2: Prime Factorization

1. Find prime factorization of each number

2. Identify common prime factors

3. Multiply common primes (use lowest occurrence count)

Method 3: Euclidean Algorithm

GCD(a, b) = GCD(b, a mod b)

Repeat until remainder = 0

For multiple numbers: GCF(x,y,z) = GCF(GCF(x,y), z)

lightbulbExamplesexpand_more

Example 1: GCF(18, 27) using Factorization

Factors of 18: 1, 2, 3, 6, 9, 18

Factors of 27: 1, 3, 9, 27

Common factors: 1, 3, 9

GCF = 9

Example 2: GCF(20, 50, 120) using Prime Factorization

20 = 2 × 2 × 5

50 = 2 × 5 × 5

120 = 2 × 2 × 2 × 3 × 5

Common prime factors: 2 and 5

GCF = 2 × 5 = 10

Example 3: GCF(18, 27) using Euclidean Algorithm

27 - 18 = 9

18 - 9 - 9 = 0

GCF = 9 (last non-zero result)

quizFAQexpand_more
What is the difference between GCF, GCD, and HCF?expand_more
GCF (Greatest Common Factor), GCD (Greatest Common Divisor), and HCF (Highest Common Factor) all refer to the same concept - the largest positive integer that divides all given numbers without a remainder. Different regions use different terms: GCF is common in the US, HCF in the UK, and GCD in mathematical contexts.
What is the GCF of two prime numbers?expand_more
The GCF of two different prime numbers is always 1, because prime numbers have no common factors other than 1. Numbers with a GCF of 1 are called 'coprime' or 'relatively prime.'
How is GCF used to simplify fractions?expand_more
To simplify a fraction, divide both the numerator and denominator by their GCF. For example, to simplify 18/27: GCF(18, 27) = 9, so 18/27 = (18÷9)/(27÷9) = 2/3. This gives you the fraction in lowest terms.
What is GCF(0, n)?expand_more
The GCF of 0 and any non-zero number n is |n| (the absolute value of n). This is because every non-zero integer divides 0 evenly (k × 0 = 0 for any k). However, GCF(0, 0) is undefined since there's no largest number that divides both.
Which method is best for finding GCF of large numbers?expand_more
The Euclidean algorithm is most efficient for large numbers. For example, finding GCF(182664, 154875, 137688) by listing factors would be tedious, but the Euclidean algorithm quickly finds the answer is 3 through repeated subtraction or division.