Article — Molar Mass Calculator
Molar Mass Calculator: From Chemical Formula to g/mol
Molar mass is the mass of one mole of a substance, in grams per mole. It equals the sum of every atomic mass in the formula: M = sum of (A_i · n_i). Water is 18.015 g/mol; glucose is 180.16 g/mol; sodium chloride is 58.44 g/mol. The molar mass calculator parses any chemical formula and returns the total mass plus a breakdown by element.
The same number that lists each element on the periodic table reappears in laboratory work every time a chemist weighs out a reagent. Molar mass is the bridge between the world we can see (a 5 g pile of salt on a balance) and the world we cannot (an inconceivable number of Na and Cl ions).
What molar mass measures
One mole is defined as exactly 6.02214076 × 10^23 particles, redefined in 2019 to be a fixed constant of nature. The molar mass tells you how many grams of a substance contain that many formula units. For water, one mole of H2O molecules weighs 18.015 grams. For carbon-12, one mole weighs exactly 12.000 grams, by definition the anchor of the atomic-mass scale.
Because chemistry is fundamentally about ratios of atoms (one carbon reacts with two oxygens to make CO2), expressing quantities in moles rather than grams makes stoichiometry tractable. The calculator does the conversion: enter a formula, get the molar mass, and you can divide any laboratory mass by it to recover moles.
How to calculate molar mass
The procedure has two steps. Count each element in the formula. Then sum the atomic mass times the count.
H2O 2(1.008) + 15.999 = 18.015 g/molNaCl 22.990 + 35.45 = 58.44 g/molC6H12O6 6(12.011) + 12(1.008) + 6(15.999) = 180.156 g/molH2SO4 2(1.008) + 32.06 + 4(15.999) = 98.08 g/molThe atomic-weight values come from the IUPAC 2021 standard atomic weights table, which the calculator uses internally. They are weighted averages of the natural isotope abundances; chlorine appears as 35.45 because Earth's chlorine is a 76:24 blend of Cl-35 and Cl-37.
Molar mass versus molecular weight
In casual chemistry the two terms are interchangeable. Strictly: molecular weight (or relative molecular mass M_r) is a unitless ratio of average molecule mass to 1/12 of a carbon-12 atom; molar mass is the same number expressed in grams per mole. M_r for water is 18.015 (no units); molar mass is 18.015 g/mol.
Biochemists often use daltons (Da) for protein molecular weight, where 1 Da = 1 g/mol. A 50 kDa protein has a molar mass of 50,000 g/mol. The numerical equivalence makes the units a convenience rather than a hard distinction.
Before 1961 atomic masses were normalized to oxygen-16, which gave physicists and chemists slightly different scales. The shift to carbon-12 unified the two systems and changed every periodic-table value by about 0.003%. Old textbooks list water as 18.016 g/mol; modern values give 18.015 g/mol because of refined isotope-abundance measurements.
Parentheses, hydrates, and tricky formulas
The subscript after a closing parenthesis multiplies every atom inside. Ca(OH)2 means one calcium, two oxygens, and two hydrogens. The parser handles arbitrary nesting: Mg3(PO4)2 yields three magnesiums, two phosphoruses, eight oxygens.
Hydrates are written with a center dot: CuSO4·5H2O. The dot means "plus five separately bound water molecules per copper sulfate unit." The molar mass adds 5 × 18.015 = 90.08 g/mol to the anhydrous 159.61 to give 249.69 g/mol. The calculator handles this by extending the formula: type CuSO4(H2O)5 to compute the same value.
Percent composition from molar mass
Dividing each element's contribution by the total molar mass gives its percent by mass. This is one of the most-used quantities in analytical chemistry, both for verifying compound identity and for buying materials by element content (think iron ore: weight-percent Fe is the trade metric).
| Compound | Element | Percent by mass |
|---|---|---|
| H2O | H | 11.19% |
| H2O | O | 88.81% |
| CO2 | C | 27.29% |
| CO2 | O | 72.71% |
| NaCl | Na | 39.34% |
| NaCl | Cl | 60.66% |
| Fe2O3 (hematite) | Fe | 69.94% |
Common molar masses
- H2O: 18.015 g/mol
- NaCl: 58.44 g/mol
- CO2: 44.01 g/mol
- O2: 32.00 g/mol
- N2: 28.01 g/mol
- Glucose (C6H12O6): 180.16 g/mol
- Sucrose (C12H22O11): 342.30 g/mol
- Ethanol (C2H5OH): 46.07 g/mol
- Aspirin (C9H8O4): 180.16 g/mol
- Air (mix): about 28.97 g/mol
Where molar mass shows up
Preparing solutions. Want 1 L of 0.1 M NaOH? Molar mass of NaOH is 40.00 g/mol; you need 0.1 mol = 4.00 g. Every dilution problem and every titration calculation starts with a molar-mass lookup.
Drug dosing. Most drug doses are reported in mg, but pharmacological receptor binding is expressed in molar concentration. Going from mg/kg body weight to nanomolar at the receptor requires the drug's molar mass at every step.
Combustion stoichiometry. Burning methane: CH4 + 2 O2 -> CO2 + 2 H2O. To find the mass of CO2 produced per gram of methane, divide by methane's molar mass (16.04) and multiply by CO2's (44.01); ratio 2.74 g CO2 per g methane.
Molar mass mistakes
The element oxygen has atomic mass 15.999, but molecular oxygen O2 has molar mass 31.998. Hydrogen H is 1.008 g/mol; H2 gas is 2.016 g/mol. For the seven common diatomic elements (H, N, O, F, Cl, Br, I), always check whether the problem asks for atomic or molecular mass.
Other regular slips: forgetting subscripts (counting the 2 in H2O as 1), ignoring parentheses in Ca(OH)2 and getting 57 instead of 74, mixing up atomic numbers with atomic masses (carbon is 12.011 g/mol, not 6 g/mol), and using rounded values in early steps that compound into a noticeable final error.
For laboratory work, carry one or two extra digits during intermediate steps and round only at the end. Atomic weights to three decimals (H = 1.008, C = 12.011, O = 15.999) are accurate enough for almost any practical purpose; using H = 1 introduces a 1% error that propagates through every subsequent calculation.