Skip to content
AllCalcHub

Grams to Moles Calculator

Convert between grams, moles and number of particles for any compound.

About the Grams to Moles Calculator

Type a chemical formula (case matters: Co is cobalt, CO is carbon monoxide), choose whether you have grams or moles, and enter the amount. The calculator works out the molar mass from the formula and gives the other quantity and the number of particles.

Moles = mass ÷ molar mass. One mole contains exactly 6.02214076 × 10²³ particles (the Avogadro constant, fixed exactly in the 2019 SI).

The formula

n = m ÷ M; N = n × Nₐ

n
amount, in moles
m
mass, in grams
M
molar mass, g/mol
Nₐ
Avogadro constant

Worked example

100 g of sodium chloride (NaCl)

  1. Molar mass: 22.99 + 35.45 = 58.44 g/mol
  2. n = 100 ÷ 58.44 = 1.711 mol
  3. = 1.03 × 10²⁴ formula units

Questions people ask

How many moles in 18 g of water?

About 1.0 mol (water is 18.015 g/mol).

What is a mole?

The SI unit of amount of substance: 6.02214076 × 10²³ entities.

How do I enter a hydrate?

Use · or a dot: CuSO4·5H2O.