Molecular Weight Calculator

Calculate the molecular weight of any chemical compound from its formula. Enter H2O, NaCl, or C6H12O6 for instant molar mass with element breakdown.

Enter Chemical Formula

Use standard element symbols (H, C, N, O, etc.). Numbers after symbols indicate subscripts. Parentheses supported: Ca(OH)2.

Molecular Weight of H2O

18.015

g/mol

ElElements
2
AtTotal Atoms
3

Element Breakdown

ElementCountAtomic WtContribution
H21.0082.016
O115.99915.999
Total18.015 g/mol

What Is Molecular Weight?

Molecular weight (MW), also called molar mass, is the sum of the atomic weights of all atoms in a molecule, expressed in grams per mole (g/mol). It connects the microscopic world of atoms to macroscopic measurements we can make in the laboratory—one mole of any substance has a mass equal to its molecular weight in grams.

CompoundFormulaMolecular Weight1 Mole Equals
WaterH₂O18.015 g/mol18.015 g = 6.022×10²³ molecules
Carbon dioxideCO₂44.01 g/mol44.01 g = 22.4 L at STP
GlucoseC₆H₁₂O₆180.16 g/mol180.16 g
Sodium chlorideNaCl58.44 g/mol58.44 g
AspirinC₉H₈O₄180.16 g/mol180.16 g
CaffeineC₈H₁₀N₄O₂194.19 g/mol194.19 g

Molecular Weight Formula

MW = Σ(n × Atomic Weight)

Where:

  • MW= Molecular weight (g/mol)
  • n= Number of each type of atom
  • Atomic Weight= Element's mass from periodic table

Common Atomic Weights

Knowing common atomic weights speeds up molecular weight calculations. These values come from the weighted average of naturally occurring isotopes.

ElementSymbolAtomic WeightNotes
HydrogenH1.008Lightest element
CarbonC12.011Basis for organic chemistry
NitrogenN14.007Key in amino acids
OxygenO15.999Essential for life
SodiumNa22.990Common in salts
SulfurS32.065In proteins (cysteine)
ChlorineCl35.453Halogens
CalciumCa40.078Bones, signaling
IronFe55.845Hemoglobin

Tip: For quick estimates, use whole numbers: H≈1, C≈12, N≈14, O≈16, S≈32, Cl≈35.5.

Calculating Molecular Weight Step by Step

Breaking down a molecular formula into its component atoms makes calculation straightforward.

StepActionExample: H₂SO₄
1. Identify atomsList each element and countH: 2, S: 1, O: 4
2. Find atomic weightsLook up each elementH: 1.008, S: 32.065, O: 15.999
3. MultiplyAtoms × atomic weight2×1.008, 1×32.065, 4×15.999
4. SumAdd all contributions2.016 + 32.065 + 63.996
5. Report MWFinal answer with unitsMW = 98.08 g/mol

Molecular Weight vs Formula Weight

While often used interchangeably, there's a subtle distinction between these terms.

TermApplies ToDefinitionExample
Molecular WeightCovalent compoundsMass of discrete moleculesH₂O = 18.015 g/mol
Formula WeightIonic compoundsMass of formula unitNaCl = 58.44 g/mol (no molecule exists)
Molar MassAny substanceGeneral term for bothBoth above, plus elements
Atomic WeightIndividual elementsMass of one mole of atomsFe = 55.845 g/mol

Practical note: For calculations, use "molar mass" as the universal term—it applies to everything.

Hydrates and Complex Formulas

Hydrated compounds and complex molecules require including all atoms, including waters of crystallization.

CompoundFormulaCalculationMW (g/mol)
Copper sulfate pentahydrateCuSO₄·5H₂OCu + S + 4O + 5(2H + O)249.69
Sodium carbonate decahydrateNa₂CO₃·10H₂O2Na + C + 3O + 10(2H + O)286.14
Magnesium chloride hexahydrateMgCl₂·6H₂OMg + 2Cl + 6(2H + O)203.30

Important: When preparing solutions from hydrated salts, use the MW of the hydrate, not the anhydrous form.

Converting Between Moles and Mass

Molecular weight is the conversion factor between moles (amount of substance) and mass (grams).

Starting WithTo FindFormulaUnits
Mass (g)Molesn = mass / MWmol = g / (g/mol)
MolesMass (g)mass = n × MWg = mol × (g/mol)
MolesMoleculesN = n × Nₐmolecules = mol × 6.022×10²³
Mass (g)MoleculesN = (mass/MW) × Nₐmolecules

Mole-Mass Conversions

n = mass / MW mass = n × MW N = n × Nₐ = n × 6.022×10²³

Where:

  • n= Number of moles
  • mass= Mass in grams
  • MW= Molecular weight (g/mol)
  • N= Number of molecules
  • Nₐ= Avogadro's number (6.022×10²³)

Applications of Molecular Weight

Molecular weight calculations are fundamental to nearly every quantitative aspect of chemistry.

ApplicationHow MW Is UsedExample
Solution preparationCalculate mass for target molarityMake 1 L of 0.5 M NaCl
StoichiometryConvert mass to moles for reactionsHow much product from 10 g reactant?
Percent compositionFind mass % of each elementWhat % carbon in glucose?
Molecular formulaDetermine formula from analysisUnknown compound identification
Drug dosingConvert between mass and molesmg dose to mmol
Gas calculationsMolar volume at STP (22.4 L/mol)Volume of CO₂ produced

Worked Examples

Calculate MW of Glucose

Problem:

Find the molecular weight of glucose (C₆H₁₂O₆).

Solution Steps:

  1. 1Identify atoms: 6 Carbon, 12 Hydrogen, 6 Oxygen
  2. 2Look up atomic weights: C = 12.011, H = 1.008, O = 15.999
  3. 3Calculate each element's contribution:
  4. 4Carbon: 6 × 12.011 = 72.066 g/mol
  5. 5Hydrogen: 12 × 1.008 = 12.096 g/mol
  6. 6Oxygen: 6 × 15.999 = 95.994 g/mol
  7. 7Sum: 72.066 + 12.096 + 95.994 = 180.156 g/mol

Result:

MW of glucose = 180.16 g/mol. This means 180.16 grams of glucose contains exactly 1 mole (6.022 × 10²³ molecules).

Calculate Mass from Moles

Problem:

How many grams of calcium chloride (CaCl₂) are in 0.25 moles?

Solution Steps:

  1. 1First, calculate MW of CaCl₂:
  2. 2Ca: 1 × 40.078 = 40.078 g/mol
  3. 3Cl: 2 × 35.453 = 70.906 g/mol
  4. 4MW = 40.078 + 70.906 = 110.98 g/mol
  5. 5Now convert moles to mass: mass = n × MW
  6. 6mass = 0.25 mol × 110.98 g/mol = 27.75 g

Result:

0.25 moles of CaCl₂ = 27.75 grams. This is the mass you'd weigh out to have 0.25 mol of the compound.

Calculate Percent Composition

Problem:

What is the percent composition of carbon in ethanol (C₂H₅OH)?

Solution Steps:

  1. 1Ethanol formula: C₂H₆O (2 C, 6 H, 1 O)
  2. 2Calculate MW: 2(12.011) + 6(1.008) + 1(15.999) = 46.07 g/mol
  3. 3Mass of carbon per mole: 2 × 12.011 = 24.022 g
  4. 4Percent carbon = (24.022 / 46.07) × 100 = 52.14%

Result:

Ethanol is 52.14% carbon by mass. You can similarly calculate: H = 13.13%, O = 34.73% (total = 100%).

Tips & Best Practices

  • Memorize common atomic weights for quick calculations: H≈1, C≈12, N≈14, O≈16, S≈32, Cl≈35.5.
  • For hydrated compounds, include the water molecules in your MW calculation.
  • Check your answer by ensuring the MW is reasonable for the compound size.
  • Avogadro's number (6.022 × 10²³) connects moles to individual molecules.
  • For ionic compounds, use 'formula weight' but calculate the same way as molecular weight.
  • Always include units (g/mol) in your final MW answer.
  • Online periodic tables often provide more decimal places for precise work.

Frequently Asked Questions

Atomic weights are weighted averages of all naturally occurring isotopes. Carbon has 98.9% ¹²C (mass 12) and 1.1% ¹³C (mass 13), giving an average of 12.011. For elements with significant isotope variation, this matters for precise work.
They're numerically identical but have different units. Atomic mass is the mass of a single atom or molecule in amu (or Daltons). Molecular weight is the mass of one mole in grams. One water molecule = 18.015 amu; one mole of water = 18.015 g.
Multiply everything inside the parentheses by the subscript. Ca(OH)₂ means 1 Ca, 2 O, and 2 H. So: MW = 40.078 + 2(15.999) + 2(1.008) = 40.078 + 31.998 + 2.016 = 74.09 g/mol.
A Dalton is another name for atomic mass unit, commonly used in biochemistry for proteins and biomolecules. A protein might be 50 kDa (50,000 Daltons = 50,000 g/mol). 1 Da = 1 g/mol = 1 amu.
Match precision to your data. For most calculations, 2 decimal places suffice (e.g., 180.16 g/mol). For precise analytical work, use 4+ decimal places. Never report more precision than your least precise measurement allows.
Standard atomic weights account for natural isotope abundance. If using enriched or specific isotopes (like deuterium D instead of H), use the isotope's specific mass. Heavy water (D₂O) has MW = 20.03 g/mol, not 18.01 g/mol.

Sources & References

Last updated: 2026-01-22

💡

Help us improve!

How would you rate the Molecular Weight Calculator?