Molar Mass Calculator
How it Works
01Pick Each Atom
70 elements supported — Hydrogen through Uranium with IUPAC 2021 atomic weights
02Set the Quantity
1–50 per element, side-by-side with the atom dropdown. Add up to 10 elements
03Sum Atomic Masses
M = Σ (count × atomic mass) — closed-form stoichiometric arithmetic
04Get Formula + Mass %
Empirical formula in subscript notation, total g/mol, and percent composition
What is a Molar Mass Calculator?
Every atomic mass uses the IUPAC 2021 standard atomic weight — the natural-abundance average for each element. Pick "Hydrogen" and the calculator uses 1.008 g/mol; pick "Carbon" it uses 12.011, etc. The output gives you the molar mass in g/mol (and kg/mol, plus grams per single molecule for context); the empirical formula in proper subscript notation; the percent composition by mass for each element with visual progress gauges; and — when you build a well-known compound — a "common compound match" callout for water, glucose, NaCl, caffeine, aspirin, and more.
The terms molar mass, molecular weight, molecular mass, and relative molecular mass all refer to essentially the same number with different naming conventions. The IUPAC-preferred term is "molar mass" with units of g/mol — what this calculator outputs.
Pro Tip: Pair this with our Molarity Calculator for solution-prep math, or our PPM to Molarity Calculator for environmental work where molar mass bridges mass and moles.
How to Use the Molar Mass Calculator?
How do I calculate molar mass?
Molar mass is the most basic stoichiometric calculation in chemistry — sum the atomic masses of every atom in the compound. Here's the complete breakdown:
Think of a compound's molar mass like the weight of a recipe: each ingredient (element) contributes its individual weight (atomic mass) times how much of it you use (number of atoms). Total it up and you have the weight of one "serving" — one mole — of the compound.
The Core Formula
M = Σᵢ (countᵢ × atomic_massᵢ)
Sum over all elements i in the compound. Each element contributes (count × atomic mass). Result has units of g/mol. For water (H₂O): M = 2 × 1.008 + 1 × 15.999 = 18.015 g/mol.
Standard Atomic Weights (IUPAC 2021)
The atomic mass used is the natural-abundance average — weighted by each isotope's abundance on Earth. So carbon's atomic weight is 12.011 (not exactly 12), reflecting the ~98.9% ¹²C and ~1.1% ¹³C natural mixture. Some elements have wider isotopic variability, leading to bracketed values which are conventionally rounded for routine use.
For radioactive elements with no stable isotopes (Tc, Pm, Po, At, Rn, Fr, Ra, Ac, U), the atomic weight reported is the mass number of the longest-lived isotope.
Percent Composition by Mass
%mass_i = (count_i × atomic_mass_i) ÷ M × 100%
For glucose C₆H₁₂O₆ (M = 180.156): C = 6 × 12.011 / 180.156 = 40.0% · H = 12 × 1.008 / 180.156 = 6.71% · O = 6 × 15.999 / 180.156 = 53.3%. Mass percentages always sum to 100%.
Mass per Single Molecule
m_one = M / N_A
where N_A = 6.022 × 10²³ /mol is Avogadro's number. So one water molecule weighs 18.015 / 6.022×10²³ ≈ 2.99 × 10⁻²³ g. Tiny — but with Avogadro's number of them, you get one mole = 18 grams.
Molar Mass Calculator – Compound Mass In Practice
- Step 1: Identify the elements and counts. Carbon × 8, Hydrogen × 10, Nitrogen × 4, Oxygen × 2. Four element slots needed.
- Step 2: Look up atomic masses. C = 12.011, H = 1.008, N = 14.007, O = 15.999 g/mol (IUPAC 2021).
- Step 3: Compute each contribution. C: 8 × 12.011 = 96.088. H: 10 × 1.008 = 10.080. N: 4 × 14.007 = 56.028. O: 2 × 15.999 = 31.998.
- Step 4: Sum. M = 96.088 + 10.080 + 56.028 + 31.998 = 194.194 g/mol.
- Step 5: Percent composition. C: 49.5%. H: 5.2%. N: 28.9%. O: 16.5%. Sum: 100.1% (rounding) ✓.
- Step 6: Compare to literature. Reported caffeine molar mass: 194.19 g/mol — exact match. The calculator's "common compound" callout would flag this as Caffeine immediately.
Now consider glucose (C₆H₁₂O₆): M = 6(12.011) + 12(1.008) + 6(15.999) = 72.066 + 12.096 + 95.994 = 180.156 g/mol. The "fingerprint mass" of all hexose sugars (they're isomers).
For an inorganic example: sodium chloride NaCl: M = 22.990 + 35.45 = 58.44 g/mol. One mole of table salt weighs 58.44 grams — about a tablespoon. This is also why a "1 M" NaCl solution dissolves 58.44 g per liter.
Who Should Use the Molar Mass Calculator?
Technical Reference
Standard Atomic Weights. The atomic masses used are the IUPAC 2021 standard atomic weights — the natural isotopic-abundance-weighted average for each element. Updated periodically by the IUPAC Commission on Isotopic Abundances and Atomic Weights (CIAAW).
Why the values aren't exact integers. Most elements have multiple stable isotopes. Carbon's atomic weight is 12.011 because natural carbon is ~98.9% ¹²C and ~1.1% ¹³C. Hydrogen's 1.008 reflects ~99.985% ¹H and trace ²H (deuterium).
Reference Molar Masses for Common Compounds (g/mol):
- Water (H₂O): 18.015
- Carbon dioxide (CO₂): 44.009
- Sodium chloride (NaCl): 58.44
- Sodium hydroxide (NaOH): 39.997
- Sulfuric acid (H₂SO₄): 98.079
- Hydrochloric acid (HCl): 36.458
- Nitric acid (HNO₃): 63.013
- Glucose (C₆H₁₂O₆): 180.156
- Sucrose (C₁₂H₂₂O₁₁): 342.297
- Ethanol (C₂H₅OH): 46.069
- Acetic acid (CH₃COOH): 60.052
- Aspirin (C₉H₈O₄): 180.159
- Caffeine (C₈H₁₀N₄O₂): 194.194
- Calcium carbonate (CaCO₃): 100.087
- Ammonium nitrate (NH₄NO₃): 80.043
Naming Conventions. Molar mass (IUPAC-preferred), molecular weight (older common use), molecular mass (sometimes reserved for mass per molecule), relative molecular mass — all refer to the same number with units of g/mol. The calculator outputs in g/mol and labels it "molar mass (M)".
Hill System Ordering. The standard formula-writing convention: carbon first, then hydrogen, then other elements in alphabetical order. Glucose is C₆H₁₂O₆ (Hill order). Inorganic compounds without carbon usually go alphabetically. The calculator displays the formula in input order — re-arrange your input to match Hill convention if your application requires it.
Key Takeaways
Frequently Asked Questions
What is the Molar Mass Calculator?
Output includes the empirical formula in subscript notation, molar mass in g/mol with conversions to kg/mol and grams per single molecule, percent composition by mass for each element, per-element contribution breakdown, and a common-compound match for well-known formulas (water, glucose, NaCl, caffeine, aspirin, etc.). Designed for chemistry homework, organic synthesis, biochemistry, pharmaceutical work — runs entirely in your browser.
Pro Tip: For more chemistry tools, try our Molarity Calculator.
What's the difference between molar mass, molecular weight, and molecular mass?
Why isn't carbon's atomic weight exactly 12?
Where do the atomic weights come from?
How do I include a hydrate?
What about monoisotopic mass for mass spectrometry?
Why is the maximum quantity 50 atoms per element?
Can I use this for ionic compounds?
Why does my calculated molar mass differ slightly from a textbook?
What's the relationship between molar mass and density?
Can I share or export the result?
Disclaimer
Atomic weights use IUPAC 2021 standard values based on natural isotopic abundance. For isotope-labeled compounds, use exact monoisotopic masses instead. The empirical formula is built in input order — apply Hill ordering manually if your application requires it.