This page gives you a quick way to practice converting grams to moles and moles to grams using the molar mass of any substance. You enter the mass in grams and the molar mass in grams per mole, and the calculator returns the number of moles. Below you’ll find the formula, a step-by-step worked example, common mistakes to avoid, and several practice problems with answers.
Formula
The core conversion is:
moles = mass (g) ÷ molar mass (g/mol)
In symbols: n = m / M
- n = amount of substance in moles (mol)
- m = mass of the sample in grams (g)
- M = molar mass of the substance in grams per mole (g/mol)
To go the other way, rearrange: mass (g) = moles × molar mass (g/mol).
The molar mass is the sum of the atomic weights of all atoms in the chemical formula, using the IUPAC standard atomic weights. For example, sodium chloride (NaCl) has a molar mass of 22.990 g/mol (Na) + 35.45 g/mol (Cl) = 58.44 g/mol.
Worked Example
Suppose you have 2.922 g of NaCl and want to know how many moles that is. The molar mass of NaCl is 58.44 g/mol.
Step 1: Write the formula: n = m / M
Step 2: Plug in the numbers: n = 2.922 g / 58.44 g/mol
Step 3: Divide: n = 0.05000 mol (rounded to 4 significant figures)
So 2.922 g of NaCl is exactly 0.0500 moles. The calculator above uses the same values and returns 0.0500 mol/L if you also enter a volume of 250 mL, because it computes molarity (moles per liter) as well.
Assumptions
- The substance is pure and the molar mass is correct for the given formula.
- Atomic weights are taken from the IUPAC standard (e.g., Cl = 35.45).
- For molarity, the volume is the final solution volume, not the volume of solvent added.
- The solution is assumed to be at typical lab conditions (25 °C) unless stated otherwise.
How to Choose the Right Molar Mass
The most common mistake in grams-to-moles practice is using the wrong molar mass. Here are the key points:
- Use the formula of the actual substance. For example, water (H2O) has a molar mass of 18.015 g/mol, not 17.01 (which would be hydroxide, OH−).
- Watch out for hydrates. Copper(II) sulfate pentahydrate (CuSO4·5H2O) has a molar mass of 249.69 g/mol, not the anhydrous 159.61 g/mol.
- For gases, remember that molar mass is the same as the molecular weight in g/mol. For example, oxygen gas (O2) has a molar mass of 31.998 g/mol, not 15.999 (which is atomic oxygen).
If you are converting a compound, always write out its formula and sum the atomic weights of each element multiplied by the number of atoms.
Common Mistakes and How to Avoid Them
- Unit mix-ups: Molar mass is in g/mol, so if you have mass in kilograms, convert to grams first (1 kg = 1000 g). If you have moles and want grams, multiply by molar mass, not divide.
- Forgetting to convert mL to L: In molarity calculations, volume must be in liters. The calculator does this automatically (mL / 1000).
- Rounding too early: Keep at least 4 significant figures during intermediate steps to avoid rounding errors in the final answer.
- Using the wrong formula: For a hydrate, include the water molecules in the molar mass.
Practice Problems
Try these on your own, then check the answers below.
- How many moles are in 10.0 g of sodium hydroxide (NaOH)? (Molar mass = 40.00 g/mol)
- What is the mass of 0.250 mol of calcium carbonate (CaCO3)? (Molar mass = 100.09 g/mol)
- How many moles are in 5.00 g of glucose (C6H12O6)? (Molar mass = 180.16 g/mol)
- What mass of potassium permanganate (KMnO4) is needed to have 0.0200 mol? (Molar mass = 158.03 g/mol)
Answers: 1) 10.0 / 40.00 = 0.250 mol. 2) 0.250 × 100.09 = 25.0 g (rounded). 3) 5.00 / 180.16 = 0.0278 mol. 4) 0.0200 × 158.03 = 3.16 g.
Why This Conversion Matters
Grams-to-moles is the foundation of stoichiometry. In a chemical reaction, you need to know how many moles of each reactant you have, because reactions occur in mole ratios, not mass ratios. For example, the balanced equation 2H2 + O2 → 2H2O tells you that 2 moles of hydrogen react with 1 mole of oxygen. If you have 4.0 g of hydrogen (which is about 2.0 mol), you can calculate that you need 1.0 mol of oxygen (32.0 g) to react completely. Without converting to moles, you cannot predict the amounts of products or reactants.
This conversion also appears in molarity calculations (as shown in the calculator above), in determining empirical formulas from percent composition, and in gas law problems where you need moles to use PV = nRT.
Frequently Asked Questions
How do I convert grams to moles without a calculator?
You divide the mass by the molar mass. For example, 10 g of water (molar mass 18.015 g/mol) is 10 ÷ 18.015 = 0.555 mol. You can do this by hand or with a basic calculator.
What is the difference between molar mass and molecular weight?
They are numerically the same for a molecule. Molar mass is expressed in grams per mole (g/mol) and is the mass of one mole of a substance. Molecular weight is the sum of atomic weights of the atoms in a molecule, usually expressed in atomic mass units (amu) or daltons, but the number is identical.
Why is the molar mass of an element not always a whole number?
Because it is the weighted average of all naturally occurring isotopes. For example, chlorine has two stable isotopes, Cl-35 and Cl-37, so its average atomic weight is 35.45, not a whole number.
Can I convert grams to moles for any substance?
Yes, as long as you know its chemical formula and can calculate its molar mass. This works for elements, compounds, and even mixtures if you know the average molar mass.
What if I have the mass in milligrams or kilograms?
Convert to grams first: 1 mg = 0.001 g, 1 kg = 1000 g. Then divide by molar mass. For example, 500 mg of NaCl is 0.500 g, which is 0.500 / 58.44 = 0.00856 mol.
Why does the calculator also ask for volume?
Because it gives you the molarity (concentration in mol/L) as an extra output. If you only need moles, you can ignore the volume field or leave it at the default. The moles are calculated from mass and molar mass alone.
Related
Formula used
in m | Mass of solute | g | 2.922 | 0 in mm | Molar mass | g/mol | 58.44 | 0.001 in v | Final solution volume | mL | 250 | 0.001 out c | Molarity | mol/L | m / mm / (v / 1000) | 4 out cmm | Concentration in millimolar | mM | c * 1000 | 2
Each line is one input (in, sel, list) or one result (out: label, unit, formula, decimals). How the calculators work
Method: the standard formula for this calculation with the constants and conversion factors written on the page, rounded as each result states. See method and constants, the disclaimer or report an error.
More in this section
- BPP Calculator Video: How to Use It19.29 bpp
- Convert % to ppb: Percent to Parts Per Billion1,000.00 ppb
- Extent of Reaction: What It Represents in Chemistry1.000 mol
- Reaction Quotient Q: Definition, Formula, and Use
- Standard Reaction Free Energy Calculator
- Chemical Reaction Equation: How to Write & Balance One1.0000 mol