HomeCalculatorsChemistryGrams to Moles Calculator

Grams to Moles Calculator

Chemistry

Convert grams to moles using the molar mass of any substance. Enter the mass in grams and the molar mass to get the number of moles instantly with working shown.

100 g
g
18.015 g/mol
g/mol

Moles (mol)

5.551
Molar Mass Used (g/mol)
18.015

This calculator computes your Moles (mol), Molar Mass Used (g/mol) from the values you enter.

Inputs
MassMolar Mass
Outputs
Moles (mol)Molar Mass Used (g/mol)

What is a g to mol?

The Grams to Moles Calculator converts the mass of a chemical substance in grams into the number of moles — the chemist's unit for counting particles in bulk. This single conversion step is the gateway to virtually every quantitative chemistry calculation: stoichiometry, concentration, gas law problems, and electrochemistry all require moles rather than grams as the starting quantity.

The relationship between grams and moles is defined by molar mass. The molar mass of a substance (measured in g/mol) is the mass of exactly one mole of that substance, and it equals the sum of the atomic masses of all atoms in one formula unit. For water (H₂O), the molar mass is 18.015 g/mol; for sodium chloride (NaCl), it is 58.44 g/mol. Dividing the mass in grams by the molar mass gives the number of moles directly.

Indian chemistry students first encounter this conversion in NCERT Class 11 Chapter 1 (Some Basic Concepts of Chemistry), where it is introduced alongside the mole concept and Avogadro's number. The calculation appears in CBSE board practicals, JEE Main Paper 1, JEE Advanced, and NEET — typically as the first step in multi-part problems on stoichiometry or solutions. Getting this step right sets up all subsequent calculations correctly.

In practical and industrial settings, grams-to-moles conversion is used whenever reagents must be weighed accurately for a reaction: a chemist synthesising a compound, a pharmacist compounding a medicine, or a food technologist preparing a flavour concentrate all rely on this calculation to ensure correct proportions. For the next step after finding moles — calculating the concentration of a solution — use the Molarity Calculator.

How to use this g to mol calculator

  1. Enter the Mass — type the mass of your substance into the Mass field, in grams (g). This is the actual mass you have measured or are given in a problem. For example, for 250 g of CaCO₃, enter 250.
  2. Enter the Molar Mass — type the molar mass of the substance into the Molar Mass field, in g/mol. For CaCO₃: Ca (40.078) + C (12.011) + 3 × O (15.999) = 100.086 g/mol. Look up atomic masses from the periodic table and sum them for the formula.
  3. Read Moles (mol) — the highlighted result shows the number of moles corresponding to your mass input. Use this value in balanced equation stoichiometry, concentration calculations, or gas law problems.
  4. Verify the Molar Mass Used — check that the Molar Mass Used (g/mol) output matches what you intended to enter. If it shows a different value, correct the input and recalculate.
  5. Expand the steps — click the steps panel to see the formula and arithmetic written out explicitly: moles = mass ÷ molar mass. This is the working you need for exam answers or lab reports.
  6. Proceed to the next calculation — use the moles value in whatever comes next: apply balanced equation ratios for stoichiometry, substitute into PV = nRT for gas problems, or input into the Molarity Calculator for concentration.

Formula & Methodology

Grams to moles formula:

> n = m ÷ M_r

Where:
- n = number of moles (mol)
- m = mass of substance (g)
- M_r = molar mass of substance (g/mol)

To reverse (moles to grams):

> m = n × M_r

Worked example 1 — Water:

Convert 270 g of water (H₂O, M_r = 18.015 g/mol) to moles.

- n = 270 ÷ 18.015 = 14.988 mol ≈ 15 mol

15 moles of water is the amount present in 270 g of water — a quantity that at 1 M concentration would fill 15 litres of solution.

Worked example 2 — Calcium carbonate (CaCO₃):

A chemistry student weighs out 50 g of CaCO₃ (molar mass = 100.086 g/mol) for a reaction.

- n = 50 ÷ 100.086 = 0.4996 mol ≈ 0.5 mol

From the balanced equation CaCO₃ → CaO + CO₂, 0.5 mol of CaCO₃ produces 0.5 mol of CO₂ — approximately 0.5 × 44.01 = 22 g of carbon dioxide gas at standard conditions.

Frequently Asked Questions

Converting grams to moles means finding how many moles of a substance are contained in a given mass. A mole is the SI unit for amount of substance, equal to 6.022 × 10²³ particles. The conversion uses the substance's molar mass — the mass of one mole — as the conversion factor, so the formula is moles = mass (g) ÷ molar mass (g/mol).
The formula is n = m ÷ M_r, where n is the number of moles, m is the mass in grams, and M_r is the molar mass in g/mol. For example, to convert 180 g of glucose (C₆H₁₂O₆, M_r = 180.16 g/mol) to moles: n = 180 ÷ 180.16 = 0.9991 mol ≈ 1 mol. The molar mass is specific to each substance and is calculated by summing the atomic masses of all atoms in the chemical formula.
Find the molar mass by looking up the atomic masses of each element in the periodic table and multiplying by the number of atoms of that element in the formula, then summing all contributions. For water (H₂O): molar mass = 2 × 1.008 + 1 × 15.999 = 18.015 g/mol. For NaCl: molar mass = 22.990 + 35.453 = 58.443 g/mol. Once you know the molar mass, enter it directly into the Grams to Moles Calculator.
Grams to moles finds the amount of substance from a known mass using n = m ÷ M_r. Moles to grams is the reverse: it finds the mass from a known number of moles using m = n × M_r. Both conversions use the same molar mass value; the direction depends on what you know and what you need to find. The Grams to Moles Calculator handles the first direction; multiply the moles result by the molar mass to reverse it.
The Grams to Moles Calculator is focused specifically on the mass-to-moles conversion: it takes mass and molar mass as inputs and returns moles as the primary result. The [Mole Calculator](/mole-calculator/) provides the same core conversion but additionally outputs the number of molecules using Avogadro's number. Use this calculator when you only need the mole count; use the Mole Calculator when you also need the molecule count.
Yes — the formula works for any pure substance: elements, ionic compounds, covalent compounds, and polymers. The only requirement is that you know the correct molar mass for the substance. For elements like iron (Fe), the molar mass equals the atomic mass from the periodic table (55.845 g/mol). For compounds like CaCO₃ (calcium carbonate), sum the atomic masses: 40.078 + 12.011 + 3 × 15.999 = 100.086 g/mol.
Water (H₂O) has a molar mass of 18.015 g/mol. Dividing 100 g by 18.015 g/mol gives 5.5509 mol. This means 100 g of water contains approximately 5.55 moles, or 5.55 × 6.022 × 10²³ ≈ 3.34 × 10²⁴ water molecules. This is one of the most common examples used in Class 11 chemistry and JEE problem sets.
Sodium chloride (NaCl) has a molar mass of approximately 58.44 g/mol (Na = 22.990 + Cl = 35.453). Dividing 58.44 g by 58.44 g/mol gives exactly 1.000 mole. This is the standard example for preparing a 1 molar NaCl solution: dissolve 58.44 g in enough water to make 1 litre of solution. Use the [Molarity Calculator](/molarity-calculator/) to confirm the resulting concentration.
Stoichiometry — the quantitative relationship between reactants and products in a chemical reaction — is based on molar ratios from a balanced equation, not mass ratios. Before you can apply molar ratios, you must convert the given mass of each substance into moles. The grams-to-moles conversion is therefore the first step in almost every stoichiometry problem, making it one of the most practised calculations in high school and undergraduate chemistry.
Grams-to-moles calculations appear in NCERT Class 11 Chemistry Chapter 1 (Some Basic Concepts of Chemistry) and are applied throughout Class 11 and 12 in topics such as stoichiometry, solutions (molarity and molality), electrochemistry (Faraday's laws), and gaseous state (ideal gas equation PV = nRT). They are also standard in JEE Main and Advanced, NEET, and all state board chemistry syllabi.
To convert moles back to grams, multiply the number of moles by the molar mass: m = n × M_r. For example, 3 moles of NaCl (M_r = 58.44 g/mol) = 3 × 58.44 = 175.32 g. This is the reverse of the grams-to-moles conversion and is useful when you know the mole quantity from a stoichiometric ratio and need to find the mass to weigh out in the lab.
Entering an incorrect molar mass will give a proportionally wrong answer for moles. For instance, if you enter 17 instead of 18.015 for water, you will overestimate the number of moles by about 6%. Always double-check your molar mass by summing the atomic masses from the periodic table for each element in the formula. The Grams to Moles Calculator shows the Molar Mass Used in the output so you can confirm the value applied before using the result.
Also known as
grams to molesg to molmass to molesmoles from gramsmoles calculation