This calculator finds the amount of a substance in moles from its mass and molar mass, and can also convert moles to a number of particles. Enter the mass in grams and the molar mass in grams per mole to get moles; use the particle-count output when you need atoms, molecules, or formula units.
Formula
The amount in moles is the sample’s mass divided by its molar mass:
n = m / M
- n is amount of substance, in moles (mol).
- m is sample mass, in grams (g).
- M is molar mass, in grams per mole (g/mol).
To convert moles to a count of particles, multiply by Avogadro’s exact constant:
N = n × 6.02214076 × 1023
N is the number of specified particles. The constant is 6.02214076 × 1023 particles per mole. Choose what a particle means from the substance’s formula: it may be an atom, molecule, ion, or formula unit. The mass-to-moles calculation itself does not require this second conversion.
Worked Example
For the calculator’s default values, a sample has a mass of 18.015 g and a molar mass of 18.015 g/mol. These are the values for water using the listed conventional atomic weights H = 1.008 and O = 15.999 g/mol.
- Write the formula: n = m / M.
- Substitute the values and units: n = 18.015 g / 18.015 g/mol.
- Divide: n = 1.0000 mol. The gram units cancel, leaving moles.
- For water molecules, calculate the particle count: N = 1.0000 mol × 6.02214076 × 1023 molecules/mol = 6.022 × 1023 molecules.
The calculator displays 1.0000 mol and 6.022 × 1023 particles for these defaults.
Assumptions
- The entered sample mass is the mass of the substance whose molar mass you enter; it is not mixed with another material or corrected for impurities.
- The molar mass is appropriate for the compound’s formula and stated chemical form. Atomic weights are conventional values, so a calculated molar mass is normally an appropriately rounded average.
- The particle count uses the exact Avogadro constant. It counts the entities represented by one formula unit of the chosen substance.
- This calculation is for chemistry study and lab-planning arithmetic. For bench work, follow your lab method, the safety data sheet (SDS) and your supervisor.
What You’ll Need
- The mass of the sample, measured or provided in grams. Convert other mass units before entering them: 1 kg = 1000 g and 1 mg = 0.001 g.
- The substance’s chemical formula, so you can identify its molar mass and the particle type you want to count.
- A reliable periodic table or an already provided molar mass in g/mol. For a pure compound, calculate the molar mass by adding the atomic masses of every atom in its formula.
- A calculator, or this page’s calculator. Keep extra digits during working and round the final result to match the precision of your measurements.
Step-by-Step
- Identify the substance. Check its complete chemical formula, including subscripts, parentheses, and any waters of hydration. A different formula or chemical form can have a different molar mass.
- Find the molar mass. For each element in the formula, multiply its atomic mass by the number of atoms, then add the results. For example, water, H2O, has a molar mass of 2 × 1.008 + 15.999 = 18.015 g/mol. For a hydrate, include the atoms shown after the dot and multiply them by the hydrate coefficient.
- Convert the sample mass to grams. The formula requires mass in grams when molar mass is in g/mol. Do not enter milligrams or kilograms as though they were grams.
- Divide mass by molar mass. Use n = m / M. For example, 9.00 g of water gives 9.00 g / 18.015 g/mol = 0.4996 mol (rounded). The answer is an amount of substance, not a mass or a concentration.
- Check the units and size. Grams divided by grams per mole gives moles. If the sample mass is smaller than the mass of one mole, the answer will be less than one mole; that is normal.
- Convert to particles only if needed. Multiply moles by 6.02214076 × 1023 entities/mol. State whether you mean molecules, atoms, ions, or formula units. For example, one mole of water contains one mole of water molecules, but two moles of hydrogen atoms and one mole of oxygen atoms.
- Report sensible precision. Keep unrounded values while calculating. Round the final result to a precision justified by the measured mass and molar mass; do not imply that extra calculator digits make the measurement more precise.
Common Mistakes
- Mixing mass units: entering 250 mg as 250 g makes the result 1000 times too large. Convert to 0.250 g first.
- Using the wrong molar mass: confusing a molecular formula with an empirical formula, omitting a subscript, or overlooking water of hydration changes the answer.
- Multiplying instead of dividing: to get moles from mass, divide by g/mol. Multiplication is used for the reverse conversion, from moles to mass.
- Confusing moles and particles: moles measure amount; a particle count is a number of entities. Apply Avogadro’s constant only for the latter.
- Rounding too early: rounded atomic masses or intermediate answers can introduce avoidable error. Retain adequate digits and round at the end.
- Assuming a sample is pure: if a measured mass includes moisture, solvent, or impurities, the simple calculation treats all of that mass as the named substance and may overestimate its moles.
Tips
- Write the units beside each value before calculating. They help reveal whether you have the right formula and conversions.
- Use the full formula, not just the element symbols. In Ca(OH)2, the parentheses mean there are two oxygen atoms and two hydrogen atoms.
- Keep separate calculations for different substances in a mixture. A total sample mass alone cannot tell you the moles of each component.
- For solutions, first determine the moles of solute using its mass and molar mass. Molarity requires an additional calculation using solution volume in litres; it is not the same as moles.
- When comparing answers, check whether both molar masses use the same chemical form and atomic-weight convention.
Troubleshooting
- The answer seems 1000 times too large or small: check whether the mass was in mg or kg rather than g, and convert it before entering it.
- The answer differs from a textbook value: compare the formula, subscripts, hydrate status, and molar-mass rounding. Confirm that the textbook asks for moles rather than millimoles.
- The calculator rejects a value: enter a nonnegative sample mass and a positive molar mass. Check that you have not typed a unit symbol or comma into a numeric field.
- You do not know the compound’s molar mass: identify the correct formula first, then add the atomic masses for each atom. Do not guess a molar mass from a similar compound.
- You have a solution concentration instead of a sample mass: mass divided by molar mass is not enough by itself. For a known molarity and volume, use n = cV, with volume in litres; make sure the concentration and volume refer to the same solution.
- Your experimental result is unexpectedly high: consider whether the sample contained water or impurities, whether the balance was tared, and whether the substance’s stated form matches the molar mass used.
Frequently Asked Questions
How do I calculate moles from grams?
Divide the mass in grams by the molar mass in g/mol: n = m / M.
How do I find molar mass from a chemical formula?
Multiply each element’s atomic mass by its count in the formula, then add those contributions. Include atoms inside parentheses and hydrate units.
Can the number of moles be less than one?
Yes. It simply means the sample contains less substance than one mole; small laboratory samples often do.
How many particles are in one mole?
One mole contains exactly 6.02214076 × 1023 specified entities, such as atoms or molecules.
How do I convert moles back to grams?
Multiply moles by molar mass: m = nM. Keep molar mass in g/mol to obtain mass in grams.
Are moles and molarity the same?
No. Moles measure the amount of substance. Molarity is amount per volume, expressed in mol/L.
Related
Formula used
in m | Sample mass | g | 18.015 | 0 in mm | Molar mass | g/mol | 18.015 | 0.001 out n | Amount of substance | mol | m / mm | 4 out p | Number of particles | particles | n * 6.02214076e23 | 0
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
- Molecules to Grams Calculator: Convert with Molar Mass18.0150 g
- How Many Protons Are in Potassium (K)?19 protons
- Moles of Electrons: Formula and Calculator
- Molecules to Liters Calculator: Convert Using Molarity0.1000 L
- How to Calculate mL to Moles: Formula and Calculator0.1250 mol
- Free Energy Change Calculation: ΔG Formula and Example-24.907 kJ/mol