# Molar Mass Calculator

Calculate the molar mass of any compound by entering element counts. Supports C, H, O, N, S, P, Cl, Na, K, Ca, and Fe with a full mass breakdown.

## What this calculates

Calculate the molar mass of a compound by entering how many atoms of each element it contains. The calculator sums the atomic masses and shows a detailed breakdown of each element's contribution in g/mol.

## Inputs

- **Carbon (C)** — min 0, max 200 — Number of carbon atoms. Atomic mass: 12.011 g/mol.
- **Hydrogen (H)** — min 0, max 500 — Number of hydrogen atoms. Atomic mass: 1.008 g/mol.
- **Oxygen (O)** — min 0, max 200 — Number of oxygen atoms. Atomic mass: 15.999 g/mol.
- **Nitrogen (N)** — min 0, max 200 — Number of nitrogen atoms. Atomic mass: 14.007 g/mol.
- **Sulfur (S)** — min 0, max 100 — Number of sulfur atoms. Atomic mass: 32.06 g/mol.
- **Phosphorus (P)** — min 0, max 100 — Number of phosphorus atoms. Atomic mass: 30.974 g/mol.
- **Chlorine (Cl)** — min 0, max 100 — Number of chlorine atoms. Atomic mass: 35.45 g/mol.
- **Sodium (Na)** — min 0, max 100 — Number of sodium atoms. Atomic mass: 22.990 g/mol.
- **Potassium (K)** — min 0, max 100 — Number of potassium atoms. Atomic mass: 39.098 g/mol.
- **Calcium (Ca)** — min 0, max 100 — Number of calcium atoms. Atomic mass: 40.078 g/mol.
- **Iron (Fe)** — min 0, max 100 — Number of iron atoms. Atomic mass: 55.845 g/mol.

## Outputs

- **Molar Mass** (g/mol) — Total molar mass of the compound.
- **Molecular Formula** — formatted as text — The molecular formula built from your element counts.
- **Mass Breakdown** — formatted as text — Contribution of each element to the total molar mass.

## Details

Molar mass is the mass of one mole of a substance, measured in grams per mole (g/mol). It connects the atomic scale to the lab scale, letting you convert between grams and moles.

**How to Calculate Molar Mass**

1. Write the molecular formula (for example, C6H12O6 for glucose)
2. Count the atoms of each element
3. Multiply each count by the element's atomic mass
4. Add them all up

**Worked Example: Glucose (C6H12O6)**

- Carbon: 6 x 12.011 = 72.066 g/mol
- Hydrogen: 12 x 1.008 = 12.096 g/mol
- Oxygen: 6 x 15.999 = 95.994 g/mol
- Total: 72.066 + 12.096 + 95.994 = **180.156 g/mol**

**How This Differs from Molecular Weight**

The terms "molar mass" and "molecular weight" are often used interchangeably, but molar mass specifically has units of g/mol while molecular weight is technically dimensionless (a ratio relative to 1/12 of carbon-12). In practice, the numbers are the same.

**Common Molar Masses**

| Compound | Formula | Molar Mass |
|----------|---------|------------|
| Water | H2O | 18.015 g/mol |
| Carbon Dioxide | CO2 | 44.010 g/mol |
| Table Salt | NaCl | 58.440 g/mol |
| Glucose | C6H12O6 | 180.156 g/mol |
| Sucrose | C12H22O11 | 342.297 g/mol |

## Frequently Asked Questions

**Q: What is molar mass and why does it matter?**

A: Molar mass is the mass of one mole (6.022 x 10^23 particles) of a substance in grams per mole. It is the bridge between the number of molecules and the mass you can weigh on a balance. Without it, you could not convert between grams and moles for lab work.

**Q: How is this different from the molecular weight calculator?**

A: This calculator focuses on summing atomic masses from element counts you enter directly. The molecular weight calculator offers a preset list of common compounds. Use this one when you need to build a custom formula from scratch.

**Q: Where do atomic masses come from?**

A: Atomic masses come from the periodic table and reflect the weighted average of all naturally occurring isotopes of an element. For example, carbon is 12.011 g/mol because natural carbon is mostly carbon-12 with a small fraction of carbon-13.

**Q: Can I calculate molar mass for ionic compounds?**

A: Yes. The calculation is the same: sum up the atomic masses of all atoms in the formula unit. For ionic compounds like NaCl, the result is called the formula mass rather than molecular mass, but the number and units are identical.

---

Source: https://vastcalc.com/calculators/chemistry/molar-mass
Category: Chemistry
Last updated: 2026-04-08
