MaximCalculator Free, fun & accurate calculators
Platinum math layout
🌙Dark Mode

GCF Calculator (Greatest Common Factor)

Find the GCF (also called GCD) of 2–6 integers in seconds. Great for simplifying fractions, reducing ratios, and splitting things evenly — with step-by-step Euclidean Algorithm work.

Instant GCF for 2–6 numbers
🧠Euclidean steps shown
📉Perfect for simplifying fractions
📱Shareable, screenshot-friendly results

Enter your numbers

Type 2 to 6 whole numbers. You can also paste a list like 48, 180, 96 or 144 60. Negatives are allowed (we use absolute values).

🔢
🧾
📌
Your GCF result will appear here
Enter 2–6 integers and tap “Calculate GCF.”
Tip: Use this to simplify fractions and ratios fast.
Quick sense-check: the GCF can’t be larger than the smallest number you entered.
1MediumMax possible
📚 Guide

Greatest Common Factor (GCF) Calculator

The Greatest Common Factor — also called the Greatest Common Divisor (GCD) — is the largest whole number that divides two or more integers without leaving a remainder. If you’ve ever simplified a fraction, reduced a ratio, split items evenly, or looked for the “biggest number that fits into all of them,” you’ve used the GCF.

This calculator finds the GCF for two up to six numbers instantly. It also shows the steps using the Euclidean Algorithm (the fastest classic method), and (optionally) explains how prime factorization connects to the same answer. Because it’s built for real life, you can paste values separated by commas or spaces, mix positives and negatives, and get a clean result.

Quick definition
  • Factor: a number that divides another number evenly.
  • Common factor: a factor shared by multiple numbers.
  • Greatest common factor (GCF): the largest shared factor.
Why people search “GCF”
  • Simplify fractions: reduce 84/126 by dividing top and bottom by the GCF.
  • Reduce ratios: turn 18:24 into 3:4.
  • Split evenly: package items into identical groups with no leftovers.
  • Math homework: factor expressions, solve word problems, check divisibility.

The main formula idea

There isn’t a single “plug-and-chug” formula for GCF the way there is for percentage or area. Instead, we use algorithms — a repeatable process that always ends with the correct answer. The most famous is the Euclidean Algorithm:

  • GCF(a, b) = GCF(b, a mod b), until the remainder becomes 0.
  • When the remainder is 0, the last non-zero divisor is the GCF.

Here a mod b means “the remainder when a is divided by b.” This method is fast even for large numbers, and it’s what many programming languages use under the hood.

Step-by-step example (Euclidean Algorithm)

Let’s find the GCF of 252 and 105.

  1. 252 ÷ 105 = 2 remainder 42 → 252 = 105×2 + 42
  2. 105 ÷ 42 = 2 remainder 21 → 105 = 42×2 + 21
  3. 42 ÷ 21 = 2 remainder 0 → 42 = 21×2 + 0

The remainder hit 0, so the last non-zero divisor is 21. That means: GCF(252, 105) = 21.

How the calculator handles multiple numbers

For three or more numbers, we apply the GCF repeatedly:

  • GCF(a, b, c) = GCF(GCF(a, b), c)
  • GCF(a, b, c, d) = GCF(GCF(GCF(a, b), c), d)

So if you enter 48, 180, 96, the tool computes GCF(48,180) first, then takes the result with 96. This is efficient and guarantees correctness.

Prime factorization view (same answer)

Another way to think about GCF is through prime factors. If you break each number into primes, the GCF is the product of the primes they share, using the smallest exponent each prime appears with.

Example: Find the GCF of 72 and 90.

  • 72 = 2³ × 3²
  • 90 = 2¹ × 3² × 5¹

Common primes are 2 and 3. Take the smaller powers: 2¹ and 3². So GCF = 2¹ × 3² = 2 × 9 = 18.

Prime factorization is great for understanding, but for large numbers it can be slower than Euclid. That’s why this calculator uses Euclid for speed and shows steps in an easy-to-follow way.

How to use this GCF calculator

  1. Enter numbers: Type 2–6 whole numbers (integers). You can also paste a list like 12, 18, 30.
  2. Choose output style (optional): You can display the result as just the number or as a sentence.
  3. Click “Calculate GCF”: The tool shows the GCF plus step-by-step Euclidean work.
  4. Share or save: Copy the result, share it, or save it locally on your device for quick comparisons.

Common mistakes (and how to avoid them)

  • Mixing up GCF and LCM: GCF is the biggest shared factor; LCM is the smallest shared multiple.
  • Forgetting negatives: The GCF is always reported as a positive number. We use absolute values.
  • Including decimals: GCF is defined for integers. If you have decimals, convert to fractions first.
  • Assuming the GCF is 1 only when numbers are prime: Many non-prime pairs still have GCF 1 (coprime).

Real-life examples that feel “viral” (try them)

If you want a quick shareable “math flex,” try these in the calculator:

  • Sibling snack split: 84 cookies and 126 candies → GCF = 42. You can make 42 identical bags.
  • Workout sets: 48 pushups, 180 situps, 96 squats → GCF = 12. That’s 12 equal mini-circuits.
  • Music loops: Two beats at 72 and 90 counts → GCF = 18. They align every 18 counts.
  • School supplies: 60 pencils and 48 erasers → GCF = 12. Make 12 equal kits.

GCF vs. LCM (short and clear)

People often confuse these because both involve “common.” Here’s the difference:

  • GCF: largest number that divides all numbers.
  • LCM: smallest number that all numbers divide into.

Fun fact: for two numbers a and b, GCF(a, b) × LCM(a, b) = |a × b|. That relationship can help you check your work.

FAQ

  • Is GCF the same as GCD?

    Yes. Different textbooks use different terms: Greatest Common Factor (GCF) and Greatest Common Divisor (GCD) mean the same thing.

  • What if one of my numbers is 0?

    The GCF of (a, 0) is |a|. For multiple numbers, zeros don’t change the GCF unless all numbers are 0. If all inputs are 0, the GCF is undefined — the tool will tell you to enter at least one non‑zero number.

  • Can the GCF be larger than one of the numbers?

    No. The GCF is always ≤ the smallest absolute value in your list, because it must divide every number.

  • How do I simplify a fraction with the GCF?

    Compute GCF(numerator, denominator) and divide both by that GCF. Example: 84/126 → GCF = 42 → (84÷42)/(126÷42) = 2/3.

  • Why does Euclid’s algorithm work?

    Because any number that divides both a and b also divides (a − b×k). The remainder r = a mod b is exactly that kind of difference. So the set of common divisors stays the same as you replace (a, b) with (b, r), until r becomes 0.

  • What does “coprime” mean?

    Two numbers are coprime if their GCF is 1. Example: 35 and 64 are coprime (no shared prime factors).

  • Does this calculator store my numbers?

    No. All calculations run in your browser. If you click “Save Result,” it stores only the result locally on your device using localStorage.

Educational note: This GCF calculator is designed to be accurate and beginner-friendly. For formal math proofs or advanced number theory, consult a textbook or teacher. For everyday simplifying and checking, this tool is perfect.

GCF shortcuts you can do in your head

While the calculator is fastest, it’s useful to know a few mental shortcuts — especially for quick checks:

  • If both numbers are even, at least 2 is a common factor. Keep dividing by 2 until one becomes odd.
  • If both end in 0 or 5, at least 5 is a common factor.
  • If digit sums are multiples of 3, the number is divisible by 3. If both are, then 3 is a common factor.
  • If both are multiples of 9 (digit sum multiple of 9), then 9 is a common factor.
  • If one number is a multiple of the other, the smaller number is the GCF. Example: GCF(18, 54) = 18.

Divisibility rules that help you guess the GCF

Divisibility rules don’t replace Euclid, but they help you spot big common factors quickly:

  • 2: last digit is even (0,2,4,6,8).
  • 3: sum of digits is divisible by 3.
  • 4: last two digits form a number divisible by 4.
  • 5: last digit is 0 or 5.
  • 6: divisible by both 2 and 3.
  • 8: last three digits form a number divisible by 8.
  • 9: sum of digits is divisible by 9.
  • 10: last digit is 0.

How GCF shows up in algebra (factoring)

In algebra, “factoring out the GCF” is one of the first techniques you learn because it simplifies expressions and reveals structure. If you have:

12x + 18

The GCF of 12 and 18 is 6, so you can factor:

12x + 18 = 6(2x + 3)

That’s useful for simplifying, solving equations, and working with polynomials. The same idea extends when variables are included — you take the greatest shared numerical factor and the smallest powers of shared variables.

More worked examples

Example 1: GCF of 144 and 60

  1. 144 mod 60 = 24
  2. 60 mod 24 = 12
  3. 24 mod 12 = 0 → GCF = 12

Example 2: GCF of 81, 153, and 45

  • First: GCF(81, 153)
  • 153 mod 81 = 72
  • 81 mod 72 = 9
  • 72 mod 9 = 0 → GCF(81,153)=9
  • Then: GCF(9, 45) = 9

So the GCF of all three numbers is 9.

Troubleshooting: when results look “too small”

  • If you expected a big number but got 1: the numbers are likely coprime. Try prime factorization to confirm.
  • If you included a decimal: convert to an integer form (e.g., multiply by 10 or 100) or use a fraction tool first.
  • If you pasted separators: commas, spaces, and line breaks are fine; other characters will be ignored.
  • If you used huge values: Euclid still works quickly — but make sure you didn’t accidentally include a comma inside a number format like “1,000”.

Mini glossary

  • Integer: a whole number (…, -2, -1, 0, 1, 2, …).
  • Remainder: what’s left after dividing.
  • Multiple: result of number × integer (e.g., 5, 10, 15 are multiples of 5).
  • Prime: a number with exactly two positive divisors: 1 and itself.
  • Composite: a number that is not prime (has more than two divisors).

If you’re using this for school, a nice habit is to write your final result as a sentence: “The GCF of 48 and 180 is 12.” It makes your work clearer and easier to grade.

🔗 Related Math Tools

More calculators you’ll probably use next

These are hand-picked from our Math & Conversion category to pair perfectly with GCF.

Accuracy note: This calculator uses the Euclidean Algorithm (standard in math and programming) and reports the GCF as a positive integer.