Molar Mass Calculator
Molar mass of any chemical formula, with a full element-by-element breakdown.
🔒 Runs entirely in your browser — nothing here is ever uploaded
About the Molar Mass Calculator
Computes the molar mass of a chemical compound from its formula, parsing element symbols, subscript counts, and simple parenthesized groups with a dedicated small parser, against a table of common elements' IUPAC standard atomic weights.
- Enter a chemical formula using standard notation (e.g. H2O, NaCl, C6H12O6, Ca(OH)2).
- Read the total molar mass and the element-by-element breakdown.
C6H12O6 (glucose): 6 carbon + 12 hydrogen + 6 oxygen = 180.156 g/mol, matching glucose's real published molar mass.
| Element | Atomic weight | Element | Atomic weight |
|---|---|---|---|
| H | 1.008 | Na | 22.990 |
| C | 12.011 | Cl | 35.45 |
| N | 14.007 | Ca | 40.078 |
| O | 15.999 | Fe | 55.845 |
Uses IUPAC conventional standard atomic weights for roughly 30 common elements. Supports element+count notation and simple parenthesized groups, but not hydrate notation, isotope notation, or ionic charges. Parsing uses a small custom parser — never JavaScript's eval() or Function() on user input.
- • Element symbols are case-sensitive, like real chemical notation.
- • Use parentheses with a trailing count for repeated groups, like Ca(OH)2 or Al2(SO4)3.
- • This tool doesn't support hydrate notation like CuSO4·5H2O.
- IUPAC — Standard Atomic Weights — accessed 2026-08-30