lcmlab. A little clarity for your math.
SHARED FACTORS. SIMPLE STEPS.

GCF calculator

Find the greatest common factor—and understand what your numbers have in common.

01 / YOUR INPUTLet's work it out

Enter 2–20 whole numbers, separated by commas or spaces. Each number must be 0–1 billion.

Try one:
Exact answers. Clear working. No account needed.
02 / YOUR ANSWERReady to calculate
GREATEST COMMON FACTOR
—

THE WHY BEHIND THE ANSWER

Two ways to find the common factor.

What is the greatest common factor?

The greatest common factor (GCF) is the largest positive integer that divides every number in a set without a remainder. It is also called the greatest common divisor (GCD) or highest common factor (HCF).

For 24 and 36, the common positive factors are 1, 2, 3, 4, 6, and 12. The largest is 12, so GCF(24, 36) = 12.

How to find the GCF

  1. Write each number as a product of prime factors.
  2. Keep only primes that appear in every number.
  3. For each shared prime, take its smallest exponent and multiply.

For 24 = 2³ × 3 and 36 = 2² × 3², keep 2² × 3 = 12. This differs from the LCM method, which takes every prime at its highest power.

A short Euclidean example

36 = 1 × 24 + 12, then 24 = 2 × 12 + 0. The last nonzero remainder is 12, so GCF(24, 36) = 12.

See both methods for these numbers.

Use the GCF to simplify fractions

Divide a fraction's numerator and denominator by their GCF. For 24/36, divide both by 12 to get 2/3. To add fractions instead, use the LCD calculator to find a shared denominator.

For the factors behind this method, see OpenStax: prime factorization. Inputs are limited to 2–20 whole numbers from 0 to 1 billion; negative and fractional values are rejected. The zero convention is explained below.

GOOD QUESTIONS

A little more clarity.

Are GCF, GCD, and HCF the same thing?

Yes. Greatest common factor, greatest common divisor, and highest common factor refer to the same value.

What if the numbers have no shared prime factors?

Their GCF is 1. Such numbers are called coprime. For example, GCF(35, 64) = 1.

Can I enter zero?

Yes. GCF(0, n) = n for positive n. If every input is zero, this tool returns 0 by convention; there is no greatest positive common divisor in that case.

How does the Euclidean algorithm work?

Repeatedly divide and replace the pair with the divisor and remainder. When the remainder is zero, the last nonzero divisor is the GCF. For more than two numbers, repeat with each next input.

Your numbers stay yours.

Calculations and image recognition run in your browser. This app does not store images, numbers, or a calculation history on a server. Recognition software and language data are downloaded from jsDelivr. Fonts load through Google Fonts. These providers receive standard connection information such as your IP address. Shared links include the numbers in the URL. Hosting may process standard access logs. No advertising or analytics scripts are installed.