Other Calculators

Molecular Weight Calculator

Enter a chemical formula or choose a common chemical

Molar mass: 18.015 g/mol

Formula
H2O
Molar mass
18.015 g/mol
Total atoms
3

Element composition

H (Hydrogen)
2 × 1.008 = 2.016 g/mol (11.19%)
O (Oxygen)
1 × 15.999 = 15.999 g/mol (88.81%)

Element composition by mass

Mass11%89%
  • H (Hydrogen)2.0211.2%
  • O (Oxygen)1688.8%
Molarity is moles of solute per liter of solution. The mass route divides solute mass by molar mass before dividing by volume. Molecular weight uses abridged standard atomic weights with uncertainty ignored. Parts per million and per billion assume a dilute aqueous solution with a density of 1 kg/L.

What this calculator does

The Molecular Weight Calculator reads a simple chemical formula and returns its molar mass in grams per mole. It also lists each element in the formula, the number of atoms of that element, its atomic weight, its mass subtotal, and its percentage of the total mass.

The calculation uses abridged standard atomic weights published by IUPAC, with uncertainty ignored. Molecular weight, molar mass, and relative molecular mass are often used interchangeably, although they have slightly different formal definitions. For practical stoichiometry, the value in grams per mole is what matters.

How to use this calculator

  1. Enter a chemical formula such as H2O, NaCl, or C6H12O6. Element symbols are case-sensitive: the first letter is uppercase and the second letter, when present, is lowercase.
  2. Alternatively, choose a common chemical from the selector to fill the formula.
  3. Click Calculate.
  4. Review the molar mass and the element composition table.

The default formula is H2O, water. Its molar mass is 18.015 g/mol, made up of 2 hydrogen atoms at 1.008 g/mol each and 1 oxygen atom at 15.999 g/mol. Sodium chloride, NaCl, gives 58.44 g/mol, and glucose, C6H12O6, gives 180.156 g/mol.

Formulas

For a formula containing elements E₁, E₂, and so on, the molar mass is the sum of each element's atomic weight multiplied by its atom count:

molar mass = Σ (atomic weight × atom count)

For water:

H: 2 × 1.008  = 2.016
O: 1 × 15.999 = 15.999
Total          = 18.015 g/mol

The mass percentage of an element is its subtotal divided by the total molar mass, multiplied by 100.

What the results mean

The headline result is the molar mass in grams per mole. The composition table shows how much of that mass comes from each element. For H2O, hydrogen contributes about 11.19% of the mass and oxygen contributes about 88.81%, even though hydrogen accounts for two of the three atoms. This difference occurs because oxygen atoms are much heavier than hydrogen atoms.

The total atom count is also shown. It is the sum of all atom counts in the formula and is useful for checking that the formula was parsed as intended.

Assumptions and limitations

  • Only simple formulas are supported. Parentheses, brackets, dots, and hydrates such as Ca(OH)2 or CuSO4·5H2O are rejected rather than guessed.
  • Formula parsing is case-sensitive. "Co" is cobalt, while "CO" is carbon monoxide.
  • Abridged standard atomic weights are used. Results may differ slightly from isotope-specific masses or full uncertainty budgets.
  • The calculator does not determine molecular structure, bond order, charge, or whether a formula is stable.
  • Counts must be positive whole numbers without leading zeros; counts above 10,000 are rejected.
  • Unknown symbols produce an error instead of a partial result.
  • The result is a molar mass in grams per mole, not a molecular mass in daltons for a specific isotope.

Frequently asked questions

How do I calculate the molecular weight of water?

Add the atomic weights of two hydrogen atoms and one oxygen atom: 2 × 1.008 + 15.999 = 18.015 g/mol.

Why is the formula case-sensitive?

Chemical symbols use capitalization to distinguish elements. Co is cobalt, CO is carbon monoxide, and co is not a valid element symbol. The calculator rejects lowercase element starts so that ambiguous input is not silently misread.

Can I enter Ca(OH)2?

Not in this version. Parentheses, brackets, and hydrate dots are not supported. For a formula with parentheses, expand the counts manually or use a calculator that supports group notation.

Why do the mass percentages not always add up to exactly 100%?

Each percentage is rounded for display, so the visible values can total slightly above or below 100% even though the full-precision calculation is consistent.

Reference tables

Worked example: water (H₂O)

AtomCountAtomic Weight (g/mol)Mass Subtotal (g/mol)
H21.0082.016
O115.99915.999
Total3—18.015

Common elements

Atomic weights are abridged standard atomic weights. Density and phase refer to the element at room temperature and pressure; values vary with allotrope and conditions.

Atomic NumberSymbolNameAtomic Weight (g/mol)Density (g/cm³)Phase at Room Temp.
1HHydrogen1.0080.00009Gas
6CCarbon12.0112.267Solid
7NNitrogen14.0070.00125Gas
8OOxygen15.9990.00143Gas
11NaSodium22.9900.971Solid
12MgMagnesium24.3051.738Solid
13AlAluminum26.9822.70Solid
14SiSilicon28.0852.329Solid
15PPhosphorus30.9741.823Solid
16SSulfur32.062.07Solid
17ClChlorine35.450.00321Gas
19KPotassium39.0980.862Solid
20CaCalcium40.0781.55Solid
26FeIron55.8457.874Solid
29CuCopper63.5468.96Solid
30ZnZinc65.387.134Solid
47AgSilver107.86810.49Solid
79AuGold196.96719.32Solid

Source

Reference: Calculator.net — Molecular Weight Calculator. Atomic weights are abridged standard atomic weights published by IUPAC.

Disclaimer

This calculator is intended for education and routine chemistry calculations. It does not replace a validated chemical database, a laboratory information system, or professional judgment about chemical identity and safety.

Other Calculators