Molar mass calculator with steps and percent composition

Type any chemical formula to get its molar mass in grams per mole, with a step-by-step breakdown by element and the percent composition by mass.

Result · C6H12O6180.156 g/mol
Name#g/mol%
Carbon 6 72.066 40%
Hydrogen 12 12.096 6.71%
Oxygen 6 95.994 53.28%

Full page: molar mass of C6H12O6

How to use the calculator

Type a formula using ordinary numbers, such as H2SO4 or C6H12O6, and press Calculate, or tap an example. Symbols are case-sensitive: Co is cobalt, but CO is carbon monoxide.

Parentheses and square brackets work, as in Ca(OH)2. For a hydrate, put a dot before the water and its count, as in CuSO4·5H2O (a period also works). You get the molar mass to three decimal places, plus each element's atom count, mass contribution and percentage.

Worked example: sulfuric acid, H₂SO₄

One unit of H₂SO₄ contains 2 hydrogen atoms, 1 sulfur atom and 4 oxygen atoms. Multiply each count by the element's atomic mass: hydrogen 2 × 1.008 = 2.016 g/mol, sulfur 1 × 32.06 = 32.060 g/mol, and oxygen 4 × 15.999 = 63.996 g/mol.

Add the subtotals: 2.016 + 32.060 + 63.996 = 98.072 g/mol. The percent composition comes from the same numbers: hydrogen is 2.016 ÷ 98.072 × 100 = 2.06%, sulfur 32.69% and oxygen 65.25%.

Hydrates work the same way. For copper(II) sulfate pentahydrate, CuSO₄·5H₂O, add the molar mass of CuSO₄ (159.602 g/mol) to five waters (5 × 18.015 = 90.075 g/mol) to get 249.677 g/mol.

The formula explained

Molar mass (M) is the mass of one mole of a substance in grams per mole. For a compound, M is the sum of n × A over every element, where n is the number of atoms of that element and A is its atomic mass. A number after parentheses multiplies everything inside, so Ca(OH)₂ has 1 calcium, 2 oxygen and 2 hydrogen atoms.

Percent composition is (n × A ÷ M) × 100 for each element. Molar mass also converts mass to moles: moles = mass ÷ M, so 49.036 g of H₂SO₄ is 0.500 mol.

Tips: why answers can differ slightly

Textbooks round atomic masses differently, so answers can differ in the last decimal places: a book that uses 32.065 for sulfur gets 98.077 g/mol for H₂SO₄. Use the values your exam gives. For an ion such as SO₄²⁻, type SO4 without the charge; the electrons' mass is negligible.

FAQ

What is the molar mass of water?

The molar mass of water (H₂O) is 18.015 g/mol: two hydrogen atoms at 1.008 g/mol each plus one oxygen at 15.999 g/mol, so 2.016 + 15.999 = 18.015 g/mol.

What is the molar mass of NaCl?

Sodium chloride has a molar mass of 58.44 g/mol: 22.99 g/mol for sodium plus 35.45 g/mol for chlorine.

Is molar mass the same as molecular weight?

They have the same number but different units. Molecular weight (relative molecular mass) has no unit, so water's is 18.015, while its molar mass is 18.015 g/mol.