← All calculators

Grams To Moles Calculator

Convert grams to moles with our easy-to-use grams to moles calculator. Enter the mass of your substance in grams and its molar mass to calculate the amount of substance in moles. Whether you're solving a chemistry homework problem, preparing for a lab, or checking a chemical calculation, this tool helps you get your answer quickly using a simple, reliable formula.

Scroll for the full guide
  • To convert grams to moles, divide the mass in grams by the substance’s molar mass.
  • Molar mass is expressed in grams per mole (g/mol).
  • The formula is moles = mass in grams ÷ molar mass.
  • Different substances have different molar masses, so the correct value is essential.
  • A mole represents exactly 6.02214076 × 10²³ specified elementary entities, such as atoms, molecules, or ions.
  • The calculated result is only as accurate as the mass and molar mass entered into the calculator.

How to Use the Grams To Moles Calculator

Our grams to moles calculator helps you determine the amount of a chemical substance from its mass and molar mass. You do not need to work through the equation manually, although understanding the formula can help you check your answer.

Follow these steps:

  1. Enter the mass in grams. Type the amount of the substance you have, such as 36.03 grams.
  2. Enter the molar mass. Use the molar mass of the specific substance in grams per mole (g/mol).
  3. Calculate the result. Divide the mass by the molar mass to find the amount in moles.
  4. Review your answer. Check the result and make sure the chemical formula and molar mass are correct.

For example, if you have 36.03 grams of water and use a molar mass of approximately 18.015 g/mol, the result is 2 moles of water.

If you do not know the molar mass, calculate it from the chemical formula and the relevant atomic masses before using the calculator.

What Is a Mole in Chemistry?

A mole is the SI unit used to express the amount of a substance. One mole contains exactly 6.02214076 × 10²³ specified elementary entities. These entities can be atoms, molecules, ions, electrons, or other defined particles.

The mole allows chemists to work with enormous numbers of particles using manageable quantities. Instead of counting individual molecules, you can measure a sample’s mass and use its molar mass to determine the amount in moles.

For example, one mole of water contains approximately 6.022 × 10²³ water molecules. One mole of sodium chloride represents the same number of specified formula units of sodium chloride.

Although a mole always represents the same number of entities, its mass varies depending on the substance. One mole of water has a different mass from one mole of carbon dioxide because their chemical compositions and molar masses differ.

Grams to Moles Formula

The grams to moles formula is:

Moles = Mass in Grams ÷ Molar Mass

Using symbols, the equation is:

n = m ÷ M

Where:

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

To calculate moles, divide the measured mass by the molar mass. The gram units cancel during the calculation, leaving the result in moles.

For example, suppose a sample has a mass of 10 grams and a molar mass of 20 g/mol.

Moles = 10 g ÷ 20 g/mol

Moles = 0.5 mol

The sample therefore contains 0.5 moles of the specified substance, assuming the mass and molar mass are accurate.

How to Convert Grams to Moles

Converting grams to moles involves two main steps: identifying the correct molar mass and dividing the sample’s mass by that value.

Step 1: Identify the substance

Start with the chemical formula of the substance you are measuring. For example, water is H₂O, carbon dioxide is CO₂, and sodium chloride is NaCl.

The chemical formula determines which atomic masses you need to use when calculating molar mass.

Step 2: Find the molar mass

Add the atomic masses of all atoms represented in the chemical formula. Multiply each atomic mass by the number of atoms of that element in the formula.

For water (H₂O), using commonly rounded atomic masses:

  • Hydrogen: 2 × 1.008 = 2.016
  • Oxygen: 1 × 15.999 = 15.999

Molar mass of H₂O = 18.015 g/mol.

Step 3: Divide grams by molar mass

Once you know the mass and molar mass, divide the mass by the molar mass.

If the water sample weighs 36.03 grams:

Moles = 36.03 ÷ 18.015

Moles = 2 mol.

Step 4: Check the units and significant figures

Confirm that the mass is in grams and the molar mass is in grams per mole. If the mass is given in milligrams or kilograms, convert it to grams first or use a calculator that explicitly supports those units.

Round the final answer according to the precision of the original measurements and the requirements of your assignment or experiment.

Grams to Moles Examples

These examples show how the formula works for common chemical substances. The results depend on the stated molar masses and should be treated as illustrative calculations.

Example 1: Convert 36.03 Grams of Water to Moles

Given:

  • Mass = 36.03 g
  • Molar mass of water (H₂O) = 18.015 g/mol

Calculation:

Moles = 36.03 ÷ 18.015

Answer: 2 mol of H₂O

The sample contains 2 moles of water molecules.

Example 2: Convert 29.22 Grams of Sodium Chloride to Moles

Given:

  • Mass = 29.22 g
  • Molar mass of sodium chloride (NaCl) ≈ 58.44 g/mol

Calculation:

Moles = 29.22 ÷ 58.44

Answer: 0.5 mol of NaCl

This result represents half a mole of sodium chloride formula units.

Example 3: Convert 44 Grams of Carbon Dioxide to Moles

Given:

  • Mass = 44 g
  • Molar mass of carbon dioxide (CO₂) ≈ 44.01 g/mol

Calculation:

Moles = 44 ÷ 44.01

Answer: Approximately 1.00 mol of CO₂

The result is approximately one mole. Since the original mass is given as 44 grams, the reported precision should reflect the precision of that measurement.

Example 4: Convert 5 Grams of a Substance with a Molar Mass of 25 g/mol

Not every question provides a chemical formula. If the molar mass is already known, you can use it directly.

Given:

  • Mass = 5 g
  • Molar mass = 25 g/mol

Calculation:

Moles = 5 ÷ 25

Answer: 0.2 mol

This example demonstrates the general conversion formula without requiring a specific chemical substance.

Grams to Moles Conversion Chart

The following table provides illustrative conversions for substances with different molar masses.

Mass (g) Molar Mass (g/mol) Amount (mol)
5 10 0.5
10 20 0.5
20 40 0.5
25 50 0.5
50 100 0.5
100 50 2
100 100 1

These values use example molar masses rather than representing one particular chemical. For an actual substance, use its own molar mass.

The table also illustrates why grams alone are not enough to determine the number of moles. The same mass can correspond to different amounts of substance depending on the molar mass.

How to Calculate Molar Mass from a Chemical Formula

Molar mass is the mass of a substance per mole. It is usually expressed in grams per mole (g/mol) for chemistry calculations involving gram quantities.

To calculate the molar mass of a compound:

  1. Write the correct chemical formula.
  2. Identify every element in the formula.
  3. Find the atomic mass of each element.
  4. Multiply each atomic mass by the number of atoms of that element.
  5. Add the values together.

For example, carbon dioxide has the formula CO₂.

Using approximate atomic masses:

  • Carbon: 1 × 12.011 = 12.011
  • Oxygen: 2 × 15.999 = 31.998

Total molar mass = 44.009 g/mol, commonly rounded to 44.01 g/mol.

You can then use this value in the grams to moles formula.

For compounds containing parentheses, remember to multiply the atoms inside the parentheses by the subscript outside them. For hydrates, include the water molecules shown in the formula. Incorrectly counting atoms can lead to an incorrect molar mass and therefore an incorrect number of moles.

Grams, Moles, and Molecules: What Is the Difference?

Grams, moles, and molecules describe different aspects of a chemical sample.

Grams measure mass. A balance can measure the mass of a sample in grams.

Moles measure the amount of substance. A mole represents a fixed number of specified elementary entities.

Molecules are individual chemical entities. Their number can be calculated from the amount in moles when the specified entities are molecules.

To convert moles into a number of entities, use Avogadro’s constant:

Number of entities = Moles × 6.02214076 × 10²³

For example, 2 moles of water contain approximately 1.2044 × 10²⁴ water molecules.

This is different from converting grams directly into molecules. When starting with grams, you first need the correct molar mass to determine the number of moles.

For ionic compounds such as sodium chloride, use the appropriate term “formula units” rather than molecules when describing the entities represented by the chemical formula.

Common Mistakes When Converting Grams to Moles

Even though the formula is simple, a few common errors can affect the result.

Using the wrong molar mass

Different substances have different molar masses. Check the chemical formula carefully before using a value.

Multiplying instead of dividing

To convert grams to moles, divide mass by molar mass. Multiplying these values does not produce the required conversion.

Mixing units

The standard formula uses grams and grams per mole. Convert milligrams or kilograms to grams before calculating if the calculator does not support other mass units.

Counting atoms incorrectly

Subscripts in a chemical formula indicate the number of atoms of each element. Parentheses and hydrates require additional attention when calculating molar mass.

Rounding too early

Keep enough digits during intermediate calculations, then round the final answer to an appropriate number of significant figures.

Assuming equal masses contain equal moles

A 10-gram sample of one substance may contain a different number of moles than a 10-gram sample of another substance. The molar mass determines the relationship between mass and amount.

When Do You Need a Grams to Moles Calculator?

A grams to moles calculator can be useful in several chemistry tasks.

Chemistry homework: Check calculations involving molar mass, chemical equations, and stoichiometry.

Laboratory preparation: Determine the amount of a substance from a measured mass when planning a procedure.

Chemical reactions: Convert measured reactant masses into moles before applying a balanced chemical equation.

Solution preparation: Calculate the amount of solute needed when preparing a solution with a specified concentration, alongside the additional concentration and volume calculations required.

Chemistry exam practice: Check whether you have applied the conversion formula correctly.

The calculator handles the mass-to-moles arithmetic, but you still need the correct substance, molar mass, and any additional information required for the larger problem.

Grams to Moles vs. Moles to Grams

These conversions use the same relationship between mass, molar mass, and amount of substance.

To convert grams to moles:

Moles = Grams ÷ Molar Mass

To convert moles to grams:

Grams = Moles × Molar Mass

For example, if you have 2 moles of water and its molar mass is 18.015 g/mol:

Mass = 2 × 18.015

Mass = 36.03 g.

Use the grams to moles calculation when you know the mass and need the amount in moles. Use the reverse calculation when you know the amount in moles and need the corresponding mass.

Frequently Asked Questions

How do I convert grams to moles?

Divide the mass in grams by the molar mass in grams per mole. The formula is moles = grams ÷ molar mass. You need the molar mass of the specific substance to obtain the correct result.

What is the formula for converting grams to moles?

The formula is n = m ÷ M, where n is the amount in moles, m is the mass in grams, and M is the molar mass in grams per mole.

How many moles are in 10 grams?

The answer depends on the substance’s molar mass. If the molar mass is 20 g/mol, then 10 grams contains 0.5 moles. Use the actual molar mass of your substance for a correct calculation.

How do I find molar mass?

Add the atomic masses of all atoms in the chemical formula, accounting for subscripts and parentheses. The total gives the molar mass in grams per mole when expressed using the usual chemistry units.

Can I convert grams to moles without knowing the substance?

You need the molar mass to calculate the number of moles from a mass. If the substance is unknown and its molar mass cannot be established, the conversion cannot be determined from mass alone.

Are grams and moles the same thing?

No. Grams measure mass, while moles measure the amount of substance. Molar mass connects these two quantities and allows you to convert between them.

How do I convert grams to molecules?

First, divide the mass in grams by the molar mass to calculate moles. Then multiply the number of moles by Avogadro’s constant, 6.02214076 × 10²³ entities per mole. This gives the number of specified entities, provided the substance and entity type are correctly identified.

What is the difference between molar mass and molecular mass?

Molar mass is mass per mole and is commonly expressed in g/mol. Molecular mass refers to the mass of an individual molecule, commonly expressed in atomic mass units (u or Da). Their numerical values are closely related when the usual units are used, but the quantities and units are different.

Can I use this calculator for any chemical compound?

Yes, the formula can be used for a known substance when its molar mass is available. However, the result depends on entering the correct molar mass and using the appropriate chemical formula and entity type. Mixtures and substances with variable compositions may require additional information.

Calculate Grams to Moles Now

Use the calculator at the top of this page to convert a sample’s mass into moles. Enter the mass in grams, provide the correct molar mass, and review the result.

Whether you’re checking a homework answer, working through a stoichiometry problem, or preparing for a chemistry lab, the same formula applies: divide mass by molar mass.

Important: Check your inputs before relying on the result. This calculator is an educational tool and does not replace laboratory procedures, chemical safety instructions, or appropriate professional judgment.