Math

GCD and LCM calculator

Greatest common divisor and least common multiple of several numbers.

Embed this calculator on your website

Copy this code and paste it into your page (WordPress, Wix, Webflow, HTML…). It's free: please keep the link to HOD Calc.

How it works

The GCD uses Euclid's algorithm; LCM(a, b) = a × b / GCD(a, b).

Results are for guidance only and do not replace professional advice.

Worked example

With the default values:

  • Whole numbers (separated by spaces)24 36 60

you get:

  • GCD12
  • LCM360
  • Numbers24, 36, 60

Frequently asked questions

How does the “GCD and LCM calculator” tool work?

The GCD uses Euclid's algorithm; LCM(a, b) = a × b / GCD(a, b).

What do I need to enter?

Just fill in: whole numbers. The result updates as you type.

Can you give an example?

Whole numbers (separated by spaces): 24 36 60 → GCD: 12; LCM: 360.

Is this calculator free, and is my data private?

Yes. HOD Calc is completely free with no sign-up. The calculation runs in your browser: nothing you type is sent or stored.