Education & Academic

LCM & GCF Calculator

Find the least common multiple and greatest common factor of two whole numbers.

Your inputs

Example values are filled in. Replace them with yours.

Calculator values

Your result

Example result

Least common multiple

36

Greatest common factor
6
Save or compare

Saved calculations

Save up to five results in this browser. Select up to three to compare.

    How to use the calculator

    1. Replace the example inputs with your values. Use the units shown beside each field.
    2. Select Calculate to update the answer and breakdown. Select Reset to bring back the example.

    Formula

    GCF is the largest common divisor. When either number is zero, LCM is zero. Otherwise LCM = (A ÷ GCF) × B.

    Worked example

    For 12 and 18, GCF = 6 and LCM = 36.

    Assumptions and limits

    Use nonnegative whole numbers up to one million. At least one number must be positive.