Molar Mass Calculator – Molecular Weight and Element Breakdown
Molar Mass Calculator
Enter a chemical formula to instantly calculate its molar mass and view a detailed elemental composition breakdown.
| Element | Atoms | Mass (g) | Mass % |
|---|---|---|---|
| Enter a formula to see breakdown | |||

Quick answer
A molar mass calculator works out the mass of one mole of a compound from its chemical formula. Type a formula such as C6H12O6, or tap a quick example, and click Calculate Mass. The tool adds up the atomic masses of every atom and shows the total in g/mol, plus a table of each element’s atoms, mass and mass percentage.
Our free molar mass calculator understands brackets, so formulas like Ca(OH)2 and Fe2(SO4)3 are calculated correctly. It is handy for stoichiometry, solution preparation and checking homework.
Use correct capitalisation: NaCl, not nacl, and Co (cobalt) is different from CO (carbon monoxide). For hydrates, write the water in brackets, for example CuSO4(H2O)5.
How Molar Mass Is Calculated
- Split the formula into elements and count the atoms of each.
- Multiply each count by the element’s atomic mass from the periodic table.
- Add the results to get the molar mass in g/mol.
- Divide each element’s mass by the total to get its mass percent.
Example: glucose C6H12O6 = 6 × 12.011 + 12 × 1.008 + 6 × 15.999 = 180.156 g/mol, with carbon making up 40.00% of the mass.
Molar Masses of Common Compounds
| Compound | Formula | Molar mass (g/mol) |
|---|---|---|
| Water | H2O | 18.015 |
| Carbon dioxide | CO2 | 44.009 |
| Sodium chloride | NaCl | 58.44 |
| Calcium hydroxide | Ca(OH)2 | 74.092 |
| Glucose | C6H12O6 | 180.156 |
| Sulfuric acid | H2SO4 | 98.072 |
| Copper(II) sulfate pentahydrate | CuSO4(H2O)5 | 249.677 |
How to Use the Molar Mass Calculator
Use the molar mass calculator in four steps.
Step 1: Type a Chemical Formula
Enter the formula with correct capitals and numbers, such as C6H12O6, NaCl or Mg(OH)2.

Step 2: Or Tap a Quick Example
Try Water, Carbon Dioxide, Glucose or Sulfuric Acid to fill the formula instantly.

Step 3: Read the Total Molar Mass in g/mol
Click Calculate Mass. The top card shows the molar mass, for example 180.1560 g/mol for glucose.

Step 4: Check the Elemental Composition Table
Below the total, each element is listed with its number of atoms, its mass contribution and its mass percentage.

Molar Mass vs Molecular Weight
Molar mass is the mass of one mole of a substance in grams per mole (g/mol). Molecular weight, or relative molecular mass, is the same number without units. For example, water has a molar mass of 18.015 g/mol and a relative molecular mass of 18.015.
Tips for Entering Formulas
- Use brackets for groups: Al2(SO4)3, not Al2SO43.
- Capital letter starts each element symbol; lowercase continues it (Mg, not MG).
- Write hydrates with brackets, such as CuSO4(H2O)5.
- Remove charges and state symbols like (aq) or (s) before calculating.
Why Use a Molar Mass Calculator?
Adding atomic masses by hand is slow and easy to get wrong, especially for large molecules or formulas with brackets. A molar mass calculator gives an exact answer in seconds and a composition breakdown you can use for percent composition questions.
Frequently Asked Questions
Is this molar mass calculator free?
Yes. It is free with no sign-up.
Does it support brackets?
Yes. Formulas such as Ca(OH)2 and Fe2(SO4)3 are calculated correctly.
What is the molar mass of water?
About 18.015 g/mol.
How do I enter a hydrate?
Put the water in brackets with the count after it, for example CuSO4(H2O)5.
Why do I get an error or wrong value?
Check capitalisation and brackets. Co is cobalt, while CO is carbon and oxygen.
What units are used?
Molar mass is shown in grams per mole (g/mol).