GCF Calculator
Find the greatest common factor (GCF / HCF) of two or more whole numbers, with the prime-factor breakdown behind it. Calculates in your browser.
Greatest common factor
-
Show the math
The GCF is found with the Euclidean algorithm, applied across the list:
gcd(a, b) = gcd(b, a mod b)
The largest number that divides every input with no remainder. A GCF of 1 means the numbers share no common factor. All math runs locally in your browser.
What this does
The GCF calculator finds the greatest common factor (also called the greatest common divisor (GCD) or highest common factor (HCF)) of two or more whole numbers. That is the largest number that divides all of them with no remainder.
How to use it
- Enter two or more whole numbers, separated by spaces or commas.
- Read the greatest common factor.
- Use it to reduce fractions or split quantities evenly.
How it works
It repeatedly applies the Euclidean algorithm across the list. Zeros are ignored, and the GCF of a single number is that number.
gcd(a, b) = gcd(b, a mod b)
Understanding your result
The GCF is the biggest factor every number shares, so it is what you divide by to reduce a fraction to lowest terms or to split items into the largest equal groups. If the GCF is 1 the numbers are coprime (they share no factor beyond 1) which is common with consecutive numbers.
Example
The GCF of 12, 18 and 24 is 6, because 6 divides all three and nothing larger does.
Sources & methodology
Last updated .
Frequently asked questions
What is the difference between GCF, GCD and HCF?
They are three names for the same thing, the largest number that divides every input with no remainder. GCF (factor), GCD (divisor) and HCF (highest common factor) are interchangeable.
Can I enter more than two numbers?
Yes. Enter as many whole numbers as you like, separated by spaces or commas, and the calculator finds the factor common to all of them.
What if the answer is 1?
A GCF of 1 means the numbers are coprime, they share no common factor other than 1. This is common for consecutive integers.
Is my data stored?
No. Everything is calculated locally in your browser.
Related tools
Scientific Calculator
A calculator that understands full expressions, operators, powers, parentheses, factorials, the constants π and e, and trig, log, and root functions in radians or degrees. Calculates in your browser.
Average Calculator
Paste a list of numbers to get the mean, median, mode, range, count, sum, and standard deviation at once. Calculates in your browser.
Area Calculator
Find the area of a rectangle, triangle, circle, parallelogram, trapezoid, or ellipse from its dimensions. Calculates in your browser.
Volume Calculator
Find the volume of a box, cylinder, sphere, cone, pyramid, or capsule from its dimensions. Calculates in your browser.