Greatest Common Factor Notes

Published on: November 11, 2026

This Greatest Common Factor Calculator finds the biggest whole number that divides every number in a list exactly, and shows the working at every step. For smaller numbers it lists the factors of each one, marks the factors they share, and picks the greatest. For bigger numbers it breaks each one into prime factors instead and multiplies the primes they have in common. Following the same pattern every time is what makes the greatest common factor easy to find, check, and repeat on your own.

Step-by-step method

  1. Set up the problem.
  2. List the factors of each number.
  3. Find the factors that appear in every list.
  4. Pick the greatest of those common factors.

Required knowledge

See Example 1 Hide Example 1

Problem

\(\text{GCF}(12, 18)\)

Approach

Step-by-step method

  1. Set up the problem.
  2. List the factors of each number.
  3. Find the factors that appear in every list.
  4. Pick the greatest of those common factors.

Step 1

Step 1 - Set up the problem.

In this problem: We are finding the greatest common factor of \(12\) and \(18\).

\(\text{GCF}(12, 18)\)

Step 2

Step 2 - List the factors of each number.

In this problem: The factors of \(12\) are \(1\), \(2\), \(3\), \(4\), \(6\) and \(12\). The factors of \(18\) are \(1\), \(2\), \(3\), \(6\), \(9\) and \(18\).

\(12\)1234612
\(18\)1236918

Step 3

Step 3 - Find the factors that appear in every list.

In this problem: Comparing the lists, \(1\), \(2\), \(3\) and \(6\) are in every list.

\(12\)1234612
\(18\)1236918

Step 4

Step 4 - Pick the greatest of those common factors.

In this problem: The greatest of \(1\), \(2\), \(3\) and \(6\) is \(6\), so \(\text{GCF}(12, 18) = 6\).

\(12\)1234612
\(18\)1236918

Final Answer

\(\text{GCF}(12, 18) = 6\)
See Example 2 Hide Example 2

Problem

\(\text{GCF}(84, 126)\)

Approach

Step-by-step method

  1. Set up the problem.
  2. List the factors of each number.
  3. Find the factors that appear in every list.
  4. Pick the greatest of those common factors.

Step 1

Step 1 - Set up the problem.

In this problem: We are finding the greatest common factor of \(84\) and \(126\).

\(\text{GCF}(84, 126)\)

Step 2

Step 2 - Write each number as a product of prime factors, covered in the Prime Factorization Calculator.

In this problem: Each of \(84\) and \(126\) is broken down into primes one at a time.

\(\text{GCF}(84, 126)\)

Step 2a

Step 2a - Write the first number as a product of prime factors.

In this problem: Breaking \(84\) down gives \(84 = 2 \times 2 \times 3 \times 7\), worked through below.

\(84 = 2 \times 2 \times 3 \times 7\)

Step 2b

Step 2b - Write the second number as a product of prime factors.

In this problem: Breaking \(126\) down gives \(126 = 2 \times 3 \times 3 \times 7\), worked through below.

\(126 = 2 \times 3 \times 3 \times 7\)

Step 3

Step 3 - Find the prime factors that every number shares.

In this problem: Every number has \(2\) once, \(3\) once and \(7\) once, so those are the shared prime factors.

\(\begin{aligned}84 &= \boxed{2} \times 2 \times \boxed{3} \times \boxed{7} \\ 126 &= \boxed{2} \times \boxed{3} \times 3 \times \boxed{7}\end{aligned}\,\)

Step 4

Step 4 - Multiply the shared prime factors together.

In this problem: Multiplying the shared prime factors gives \(2 \times 3 \times 7 = 42\), so \(\text{GCF}(84, 126) = 42\).

\(\text{GCF}(84, 126) = 2 \times 3 \times 7 = 42\)

Final Answer

\(\text{GCF}(84, 126) = 42\)
See Example 3 Hide Example 3

Problem

\(\text{GCF}(18, 24, 30)\)

Approach

Step-by-step method

  1. Set up the problem.
  2. List the factors of each number.
  3. Find the factors that appear in every list.
  4. Pick the greatest of those common factors.

Step 1

Step 1 - Set up the problem.

In this problem: We are finding the greatest common factor of \(18\), \(24\) and \(30\).

\(\text{GCF}(18, 24, 30)\)

Step 2

Step 2 - List the factors of each number.

In this problem: The factors of \(18\) are \(1\), \(2\), \(3\), \(6\), \(9\) and \(18\). The factors of \(24\) are \(1\), \(2\), \(3\), \(4\), \(6\), \(8\), \(12\) and \(24\). The factors of \(30\) are \(1\), \(2\), \(3\), \(5\), \(6\), \(10\), \(15\) and \(30\).

\(18\)1236918
\(24\)1234681224
\(30\)12356101530

Step 3

Step 3 - Find the factors that appear in every list.

In this problem: Comparing the lists, \(1\), \(2\), \(3\) and \(6\) are in every list.

\(18\)1236918
\(24\)1234681224
\(30\)12356101530

Step 4

Step 4 - Pick the greatest of those common factors.

In this problem: The greatest of \(1\), \(2\), \(3\) and \(6\) is \(6\), so \(\text{GCF}(18, 24, 30) = 6\).

\(18\)1236918
\(24\)1234681224
\(30\)12356101530

Final Answer

\(\text{GCF}(18, 24, 30) = 6\)
See Example 4 Hide Example 4

Problem

\(\text{GCF}(7, 9)\)

Approach

Step-by-step method

  1. Set up the problem.
  2. List the factors of each number.
  3. Find the factors that appear in every list.
  4. Pick the greatest of those common factors.

Step 1

Step 1 - Set up the problem.

In this problem: We are finding the greatest common factor of \(7\) and \(9\).

\(\text{GCF}(7, 9)\)

Step 2

Step 2 - List the factors of each number.

In this problem: The factors of \(7\) are \(1\) and \(7\). The factors of \(9\) are \(1\), \(3\) and \(9\).

\(7\)17
\(9\)139

Step 3

Step 3 - Find the factors that appear in every list.

In this problem: Comparing the lists, \(1\) is in every list.

\(7\)17
\(9\)139

Step 4

Step 4 - Pick the greatest of those common factors.

In this problem: The only common factor is \(1\), so \(\text{GCF}(7, 9) = 1\).

\(7\)17
\(9\)139

Final Answer

\(\text{GCF}(7, 9) = 1\)