CalcSeed

GCF Calculator

Compute the largest number that divides three inputs exactly, using the Euclidean algorithm twice.

=
Quick answer: with the default inputs (48, 36, 24), the greatest common factor is 12. Change any input to update the result.
Greatest common factor
—

What this calculator does

Enter three positive integers and the calculator returns the greatest common factor: the largest number that divides all three with no remainder. At the defaults, 48, 36 and 24 share a GCF of 12 — 48 ÷ 12 = 4, 36 ÷ 12 = 3 and 24 ÷ 12 = 2, all whole. No number larger than 12 divides all three, since the next candidate, 24, fails on 36. That single number is the answer to every how-big-can-the-shared-piece-be question about the trio.

The pairwise method

gcf(a,b,c)=gcf(gcf(a,b),c)gcf(a,b,c) = gcf(gcf(a,b), c)

A factor common to three numbers is automatically common to any two of them, so the three-way GCF is found by collapsing the inputs two at a time. Take the GCF of the first pair, then take the GCF of that result with the third number. The order you pick the pairs does not matter: gcf(gcf(48, 36), 24), gcf(gcf(48, 24), 36) and gcf(gcf(36, 24), 48) all land on 12. Each collapse shrinks or holds the running answer, so the final value can never exceed the smallest pairwise GCF.

Euclidean algorithm walkthrough

Each pairwise step uses the Euclidean algorithm: divide the larger number by the smaller, keep the remainder, and repeat until the remainder is 0. For 48 and 36: 48 mod 36 leaves 12, then 36 mod 12 leaves 0, so gcd(48, 36) = 12. The second step is trivial here because 12 already divides 24 exactly — 24 mod 12 = 0 — so gcf(12, 24) = 12 and the work is done in two rounds. For large inputs the algorithm still finishes in a handful of divisions, which is why it has been the standard method for over two thousand years.

Worked example at the defaults

  • First pair: gcd(48, 36). 48 mod 36 = 12; 36 mod 12 = 0, so the GCF so far is 12.
  • Second pair: gcd(12, 24). 24 mod 12 = 0, so the GCF stays 12.
  • Check by division: 48 ÷ 12 = 4, 36 ÷ 12 = 3, 24 ÷ 12 = 2.
  • Result: gcf(48, 36, 24) = 12.

The division check doubles as a way to verify any GCF claim: divide all three inputs by the candidate and every quotient must be a whole number, while dividing by anything larger must fail at least one of them. Here 13 divides none of the three, and 24 divides 48 and 24 but not 36, so 12 stands as the largest that works.

The prime factorization view

NumberPrime factorsShared portion
482 × 2 × 2 × 2 × 32 × 2 × 3
362 × 2 × 3 × 32 × 2 × 3
242 × 2 × 2 × 32 × 2 × 3

Factoring each number into primes shows why the answer is 12: the GCF takes every prime that appears in all three factorizations, raised to the lowest power it reaches in any of them. The prime 2 appears at least twice in each number (four times in 48, twice in 36, three times in 24), and the prime 3 appears exactly once in each, so 2 × 2 × 3 = 12. The leftover 2s and 3s are what make the three numbers different from one another. This view also explains the worst case: three numbers sharing no common prime at all have a GCF of 1.

Where the GCF earns its keep

  • Simplifying fractions: 48/36 divides top and bottom by the GCF of 12 to become 4/3, fully reduced in one move.
  • Cutting material into the largest equal pieces: a 48-inch by 36-inch board yields the biggest possible square tiles at 12 inches, with no offcuts and no wasted cuts.
  • Grouping people or items evenly: 48 seniors, 36 juniors and 24 sophomores split into identical mixed teams of 12, giving 4 + 3 + 2 = 9 teams with nobody left over.
  • Rescheduling repeating tasks: events that recur every 48, 36 and 24 days all align on days that are multiples of 12, the densest possible shared grid.

When the GCF is 1

If the three inputs share no common prime, the GCF is 1 and the set is called relatively prime. Take 8, 9 and 15: 8 is 2 × 2 × 2, 9 is 3 × 3 and 15 is 3 × 5, and no prime appears in all three, so gcf(8, 9, 15) = 1. Note the subtlety: 9 and 15 share the factor 3, but 8 does not, and one holdout is enough to force the answer to 1. This matters when simplifying fractions — a GCF of 1 means the fraction is already in lowest terms and needs no work.

GCF versus LCM

The two quantities answer opposite questions. The GCF of 12 and 18 is 6, the largest piece inside both; the LCM is 36, the smallest number both divide into. For any pair, the product of the GCF and LCM equals the product of the numbers themselves: 6 × 36 = 216 = 12 × 18. If you need the other direction — the smallest shared multiple rather than the largest shared divisor — use the LCM calculator, and for both at once on the same inputs the GCD & LCM calculator shows them side by side.

Common mistakes

  • Stopping at a common factor instead of the greatest one: 6 divides 48, 36 and 24, but reporting 6 misses that 12 also works. Always push the candidate upward or run the Euclidean algorithm to be sure.
  • Testing factors of only two of the three numbers: the factor must divide every input, and a single holdout — the 8 in the 8, 9, 15 example — drops the GCF to 1.
  • Confusing the GCF with the LCM: 12 and 18 have a GCF of 6 and an LCM of 36, and mixing them up produces answers that fail the division check.
  • Including primes that appear in just one or two numbers: the prime 5 is absent from 48, 36 and 24 entirely, so it contributes nothing to their GCF.

The fastest self-check is the division test from the worked example: divide all three inputs by your answer. Whole-number quotients everywhere, and a guaranteed failure just above — that is the signature of a correct GCF.

Frequently asked questions

What is the GCF of 48, 36 and 24?

12. It divides all three (giving 4, 3 and 2), and nothing larger does, because 24 — the next shared candidate — fails to divide 36.

How do I find the GCF of three numbers?

Run the Euclidean algorithm on the first pair, then on the result and the third number. For 48, 36, 24: gcd(48, 36) = 12, then gcd(12, 24) = 12.

What is the fastest way to find the GCF by hand?

For small numbers, factor each into primes and multiply the shared primes at their lowest powers. For 48, 36, 24 that is 2 × 2 × 3 = 12. For larger numbers, the Euclidean algorithm is faster.

What if the three numbers share no common factor?

The GCF is 1 and the set is relatively prime. For 8, 9 and 15 no prime appears in all three factorizations, so gcf(8, 9, 15) = 1 even though 9 and 15 share a 3.

Is the GCF the same as the GCD?

Yes. Greatest common factor, greatest common divisor and highest common factor are three names for the same number. The calculator uses them interchangeably.

Does the order of the three inputs change the answer?

No. gcf(gcf(48, 36), 24), gcf(gcf(48, 24), 36) and gcf(gcf(36, 24), 48) all return 12, because a factor common to all three survives any pairing order.

How does the GCF help simplify a fraction?

Divide the numerator and denominator by it. The fraction 48/36 divides by 12 to give 4/3, which is fully reduced in a single step.

What is the difference between GCF and LCM?

The GCF is the largest number dividing the inputs; the LCM is the smallest number they all divide. For 12 and 18 the GCF is 6 and the LCM is 36, and their product 6 × 36 = 216 equals 12 × 18.

Can the GCF be larger than the smallest number?

No. Every common factor of the set divides the smallest member, so the GCF is at most that value. For 48, 36 and 24 the ceiling is 24, and the actual answer of 12 sits below it.

Method and sources

Calculation basis

Results follow exact mathematical definitions; the arithmetic is deterministic and can be verified by hand from the steps shown.

Last updated: November 17, 2026
Formula & data sources
  • Euclidean algorithm applied pairwise: gcf(a,b,c) = gcf(gcf(a,b), c).

Cite this page

Reference formats
APA 7CalcSeed. (2026, November 17). GCF Calculator. https://calcseed.com/c/math/gcf-calculator/
MLA 9"GCF Calculator." CalcSeed, 17 Nov. 2026, calcseed.com/c/math/gcf-calculator/.
ChicagoCalcSeed. "GCF Calculator." Last modified November 17, 2026. https://calcseed.com/c/math/gcf-calculator/

Related calculators