Math Solver
Free online math tools
Search
GCF
Number Theory

Greatest Common Factor Calculator

Find the largest positive integer that divides all your input numbers without leaving any remainders.

Preparing Greatest Common Factor Calculator
Please wait ...
Input
Enter your numbers separated by commas, spaces, or line breaks below, and calculate to find their greatest shared factor.
Input summary
Your calculator summary shows here.

Step by Step Calculation

GCF
Step by step calculation shows here
Calculate first and the full working will appear below automatically.

A Guide to Greatest Common Factors (GCF)

In arithmetic and number theory, the greatest common factor (often abbreviated as GCF, and also known as the greatest common divisor or GCD) is the largest positive integer that divides a set of numbers without leaving a remainder. A factor is any whole number that divides into another number evenly. Finding the GCF is a key skill for simplifying fractions, resolving proportions, grouping physical items into equal sections, and solving algebraic equations.

How to Find the GCF

To calculate the GCF, you can use three common methods: listing factors, prime factorization, or the classical Euclidean algorithm. Listing factors involves writing out every divisor for each number and picking the largest match.

The prime factorization method splits each number into its basic prime building blocks and multiplies the lowest power of the shared primes. The Euclidean algorithm uses repeated division (or subtraction) to find the divisor. To find the complete set of factors for a single value, use our finding complete number factors tool. To see the prime components directly, check out our dividing numbers into prime components.

GCF in Daily Scenarios

  • Reducing Fractions: To simplify a fraction to its lowest terms, you divide the top and bottom numbers by their GCF. You can check fractions using our visual fractions solver.
  • Dividing Materials: A craftsman with different lengths of wire or wood uses GCF to find the longest equal pieces they can cut without wasting material.
  • Packaging and Bundling: Retailers bundle products (like pens and notebooks) into equal packages containing the same quantity ratios, which you can resolve with our standard daily math tools.
  • Least Common Multiple: The GCF is used directly to compute LCM values, which you can check with our least common multiple solver.

The Euclidean Algorithm

The Euclidean algorithm is an extremely efficient method for finding the GCF of large numbers. The basic rule states that the GCF of two numbers also divides their difference.

By repeatedly dividing the larger number by the smaller number and taking the remainder, you quickly reduce the numbers until the remainder is zero. The last non-zero remainder is the GCF. Our online calculator performs these steps automatically, displaying the complete mathematical steps for your review.

Example of Splitting Ribbons

Suppose a teacher has two rolls of ribbon: one is 24 feet long, and the other is 36 feet long. The teacher wants to cut both rolls into pieces of equal length for a classroom project, with no leftover ribbon.

To find the longest possible pieces, we calculate the GCF of 24 and 36. The factors of 24 are 1, 2, 3, 4, 6, 8, 12, and 24. The factors of 36 are 1, 2, 3, 4, 6, 9, 12, 18, and 36. The common factors are 1, 2, 3, 4, 6, and 12. The greatest common factor is 12. The teacher should cut both ribbons into 12-foot pieces, resulting in 2 pieces from the first roll and 3 pieces from the second roll. This example illustrates how GCF coordinates optimal divisions.