Compound Molecular Weight Calculator

Enter chemical formula, including parentheses, brackets, coefficients, hydrates, dots, multipliers, and separators. Choose average atomic weights or override values for specialized calculations and workflows. Get molar mass, moles to grams conversions, and element contributions instantly. Export results to CSV or PDF with one click.

Input
Supports parentheses (), brackets [], braces {}, hydrates with · or ., and leading coefficients like 2H2O.
Overrides apply to elements listed here, leaving others unchanged.
If provided, calculates grams for the given moles.
If provided, calculates moles for the given mass.
Key Results
Per‑element Breakdown
Element Count Atomic weight (g/mol) Contribution (g/mol)
Total (g/mol) 0.0000
Example Data
Click to load Formula Description
LoadH2OWater
LoadNaClSodium chloride
LoadC6H12O6Glucose
LoadCaCO3Calcium carbonate
LoadFe2(SO4)3·9H2OIron(III) sulfate nonahydrate
LoadK4[Fe(CN)6]·3H2OPotassium ferrocyanide trihydrate
Formula Used

The molar mass M of a compound is the sum of atomic weights times their stoichiometric counts:

M = Σ (nᵢ × Aᵢ)
  • nᵢ: number of atoms of element i in one formula unit.
  • Aᵢ: standard atomic weight (g/mol). You may override values.
  • Groups in parentheses, brackets, or braces are multiplied by trailing coefficients.
  • Hydrates use a middle dot (·) or dot (.) as a separator.
  • Leading coefficients multiply the entire following unit or group.

Conversions:

grams = moles × M    and    moles = grams ÷ M
How to Use
  1. Enter the chemical formula, including any parentheses, brackets, or hydrates.
  2. Optionally provide moles or grams to compute related quantities.
  3. Set decimal places and add any atomic weight overrides if needed.
  4. Click Calculate to see molar mass and per‑element contributions.
  5. Export the breakdown using Export CSV or Export PDF.

Tip: You can click rows in Example Data to load sample formulas.

Common Elements Reference

Frequently used elements with average atomic weights (g/mol).

SymbolNameAtomic weight
Hydrate Multipliers Cheat Sheet

Mass added by water of crystallization per formula unit.

NotationMeaningAdded mass (g/mol)
Uses average atomic weights for H and O defined in this tool.
Worked Examples: Molar Mass

Computed using the same parser and weights as the calculator.

# Formula Name M (g/mol)

Related Calculators

Mole-Mass Converter CalculatorPercent Composition CalculatorMolality from Mass Calculatorparticle to mole calculatormole calculator with stepsnumber of atoms in a mole calculatormole to mass conversion calculatorpeptide molecular weight calculatoramino acid molecular weight calculatorplasmid molecular weight calculator

Important Note: All the Calculators listed in this site are for educational purpose only and we do not guarentee the accuracy of results. Please do consult with other sources as well.