Free Mole Calculator

Convert between moles, mass, and molar mass using n = mass ÷ molar mass, and instantly see how many atoms or molecules that is via Avogadro's number.

Enter the two known values — the third is calculated from n = mass ÷ molar mass. Particles = moles × Avogadro's number.

Solved for Moles
Mass18 g
Molar mass18.015 g/mol
Moles0.999167 mol
Particles6.01713 × 10^23

n = m ÷ M · m = n × M · M = m ÷ n. Avogadro's number Nₐ = 6.02214076 × 10²³ /mol. Use grams for mass and g/mol for molar mass; convert mg or kg to grams first.

Quick answer

The number of moles equals mass divided by molar mass: n = m ÷ M. For example, 18 g of water (molar mass 18.015 g/mol) is 18 ÷ 18.015 ≈ 0.9992 mol. Multiply moles by Avogadro's number (6.02214076 × 10²³ /mol) to get the number of particles, so 0.9992 mol ≈ 6.017 × 10²³ molecules.

Formula & method

Moles from mass and molar mass

n = m ÷ M
  • n amount of substance in moles (mol)
  • m mass of the sample in grams (g)
  • M molar mass in grams per mole (g/mol)

Rearranges to m = n × M and M = m ÷ n. Molar mass M is the sum of the atomic masses of every atom in the formula, read from the periodic table.

Number of particles

N = n × Nₐ,  where Nₐ = 6.02214076 × 10²³ /mol
  • N number of particles (atoms, molecules, or ions)
  • Nₐ Avogadro constant, exactly 6.02214076 × 10²³ per mole

Since the 2019 SI redefinition, Avogadro's number is an exact, defined value. One mole always contains this many elementary entities.

Examples

Example 1: Grams of water to moles
Input
mass = 18 g, molar mass = 18.015 g/mol
Result
≈ 0.999167 mol (≈ 6.01713 × 10²³ molecules)
Why
n = 18 ÷ 18.015 = 0.999167 mol. Multiply by 6.02214076 × 10²³ to get 0.999167 × 6.02214076e23 ≈ 6.01713 × 10²³ water molecules — essentially one mole, since 18 g is close to water's molar mass.
Example 2: Mass of NaCl from moles
Input
moles = 0.25 mol, molar mass = 58.44 g/mol (NaCl)
Result
14.61 g
Why
Rearrange to m = n × M = 0.25 × 58.44 = 14.61 g. Weighing out 14.61 g of table salt gives you exactly a quarter mole.
Example 3: Find the molar mass of an unknown
Input
mass = 44 g, moles = 1 mol
Result
44 g/mol
Why
M = m ÷ n = 44 ÷ 1 = 44 g/mol. A 44 g sample that you know is one mole has a molar mass of 44 g/mol, consistent with carbon dioxide, CO₂ (12.011 + 2 × 15.999 ≈ 44.01 g/mol).
Example 4: Doubling the sample
Input
mass = 36 g, molar mass = 18.015 g/mol (water)
Result
≈ 1.99833 mol (≈ 1.20343 × 10²⁴ molecules)
Why
n = 36 ÷ 18.015 = 1.99833 mol. Twice the mass of the first example gives twice the moles, and 1.99833 × 6.02214076e23 ≈ 1.20343 × 10²⁴ molecules.

When to use this tool

  • Preparing a reaction or solution and you need to weigh out a specific number of moles of a reagent.
  • Converting a measured mass into moles to balance a chemical equation or apply stoichiometric ratios.
  • Estimating the number of atoms, ions, or molecules in a sample using Avogadro's number.
  • Back-calculating an unknown molar mass from a known mass and mole count in a lab determination.

Common mistakes

  • Confusing molar mass (g/mol, e.g. 18.015 for water) with molecular weight expressed in atomic mass units (u) — the numbers match but the units differ; use g/mol here.
  • Forgetting to convert mass to grams. If your sample is in milligrams or kilograms, convert first (1 kg = 1000 g, 1 mg = 0.001 g) before dividing by molar mass.
  • Summing the wrong atoms for molar mass — count every atom in the formula, including subscripts (CO₂ is 12.011 + 2 × 15.999, not 12.011 + 15.999).
  • Dividing by zero: a molar mass or mole count of 0 makes the formula undefined, so the result is blank until you enter a valid non-zero value.

Frequently asked questions

What is the formula for calculating moles?

Moles equal mass divided by molar mass: n = m ÷ M. Mass is in grams and molar mass is in grams per mole, so the grams cancel and you are left with moles. For example, 18 g of water ÷ 18.015 g/mol ≈ 0.9992 mol.

How do I find the molar mass of a compound?

Add the atomic mass (from the periodic table) of every atom in the chemical formula. For water, H₂O, that is 2 × 1.008 + 15.999 ≈ 18.015 g/mol. For carbon dioxide, CO₂, it is 12.011 + 2 × 15.999 ≈ 44.01 g/mol.

How many particles are in one mole?

Exactly 6.02214076 × 10²³ particles — Avogadro's number. Since the 2019 SI redefinition this is a defined constant, so one mole of any substance contains this many atoms, molecules, or ions. Multiply your mole value by this number to get the particle count.

Why is 18 g of water about 1 mole?

Because water's molar mass is 18.015 g/mol, so 18 ÷ 18.015 ≈ 0.9992 mol — just under one mole. A full mole of water weighs 18.015 g. This is why chemists often treat ~18 g of water as roughly one mole for quick estimates.

What units should I use in the mole calculator?

Use grams for mass and grams per mole (g/mol) for molar mass; the result is in moles. If your mass is in kilograms or milligrams, convert to grams first (1 kg = 1000 g, 1 mg = 0.001 g) so the units are consistent.

Can I work out mass or molar mass instead of moles?

Yes. The same relationship rearranges three ways: n = m ÷ M to find moles, m = n × M to find mass, and M = m ÷ n to find molar mass. Choose which quantity to solve for and enter the other two.

Sources & references

External references open in a new tab. We are independent and not affiliated with these organizations.

  • ✓ Free to use
  • ✓ No sign-up required
  • Runs entirely in your browser — nothing is uploaded.
  • ✓ Formula and method shown above

Provided “as is” for general information only — results may be inaccurate, so verify before you rely on them. No warranty; use at your own risk.

Built and reviewed by HIFreeTools against the formula shown above and any authoritative references cited on this page. See our methodology and editorial standards.

Related tools

Embed this tool on your site

Free to embed, no sign-up. Paste this code where you want the mole calculator to appear: