Science & physics

Molar mass calculator

The molar mass of a chemical formula (H2O, C6H12O6, Ca(OH)2…) with the mass composition.

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

M = Σ (number of atoms × atomic mass). Moles = mass / M. Standard IUPAC atomic weights.

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

Worked example

With the default values:

  • Chemical formulaC6H12O6
  • Sample mass (g, optional)10

you get:

  • Molar mass180.156 g/mol
  • Moles in 10 g0.05551 mol
  • Molecules3.343 × 10^22

Frequently asked questions

How does the “Molar mass calculator” tool work?

M = Σ (number of atoms × atomic mass). Moles = mass / M. Standard IUPAC atomic weights.

What do I need to enter?

Just fill in: chemical formula, sample mass. The result updates as you type.

Can you give an example?

Chemical formula: C6H12O6; Sample mass (g, optional): 10 → Molar mass: 180.156 g/mol; Moles in 10 g: 0.05551 mol.

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.