Skip to content

Molar Mass Calculator

Any formula, with brackets, hydrates and percent composition.

Work out Molar Mass. Any formula, with brackets, hydrates and percent composition. Names the convention that makes the answer wrong.

Written and maintained by Mohit PatelLast checked August 4, 2026How we build these

A formula like Ca(OH)2 or CuSO4·5H2O, or just a name — aspirin, caffeine, baking soda. Formulas are case sensitive: CO is carbon monoxide, Co is cobalt.

Leave at zero for molar mass alone.

Molar mass (g/mol)

180.156

C6H12O6 · 24 atoms · 3 elements

Molar mass180.156 g/mol
O × 695.994 g/mol · 53.28%
C × 672.066 g/mol · 40.00%
H × 1212.096 g/mol · 6.71%

Molar mass is the sum of the standard atomic weights, each multiplied by how many times the element appears. One or more of these elements has an atomic weight that IUPAC publishes as an interval rather than a single number, because its isotopic composition varies measurably between natural sources — so the fourth decimal here carries real uncertainty and quoting eight digits would be false precision.

How the Molar Mass Calculator works

Type a formula and get its molar mass, broken down by element. Brackets nest, hydrates written with a dot work, and case is respected — CO is carbon monoxide while Co is cobalt, and silently accepting either would hand back a wrong answer with no warning.

Also known as: molecular weight calculator · formula mass calculator · molar mass of a compound · molecular mass calculator

Frequently asked questions

How do I calculate molar mass?

Add each element's standard atomic weight, multiplied by how many atoms of it the formula contains. Glucose, C₆H₁₂O₆, comes to 180.156 g/mol.

Why does my answer differ slightly from another source?

IUPAC publishes an interval rather than a single weight for elements whose isotopic composition varies between natural sources — carbon, sulfur, chlorine and others. Different tables pick different conventional values, so figures can differ in the fourth digit. This page flags when a formula contains such an element.

Does capitalisation matter?

Completely. A symbol is a capital letter optionally followed by lowercase, so CO is carbon monoxide and Co is cobalt — 28 g/mol against 59. This page rejects lowercase input rather than guessing.

How do I enter a hydrate?

Use a dot: CuSO4·5H2O or CuSO4.5H2O. The part after the dot is multiplied by its coefficient and added, giving 249.68 g/mol for copper sulfate pentahydrate.

Put this calculator on your own site

Free to use, on any site, commercial or not. Paste this where you want it to appear. It is a plain iframe, so it works in WordPress, Squarespace, Wix, Webflow, Ghost and anything else that accepts HTML.

The one-line version
<iframe src="https://www.thecalclibrary.com/embed/molar-mass-calculator" width="100%" height="640" style="border:1px solid #e2e8f0;border-radius:12px" loading="lazy" title="Molar Mass Calculator"></iframe>
<p style="font:13px/1.5 system-ui,sans-serif;margin:6px 0 0;color:#64748b">Powered by <a href="https://www.thecalclibrary.com/molar-mass-calculator" style="color:#64748b">Molar Mass Calculator</a> from The Calc Library</p>

The only condition is that the credit line below the frame stays in place. That one line is what pays for the tool being free — it is how anyone else finds it.

Related calculators