Molarity Calculator

Solve for molarity, mass, molar mass or volume of a solution.

g
g/mol
e.g. NaCl ≈ 58.44 g/mol.
L
mol/L
Molarity (mol/L)
Moles of solute
Mass of solute (g)
Volume (L)

Results update as you type.

About this calculator

Molarity is the most common way chemists express concentration: the number of moles of solute dissolved per litre of solution, M = moles / litres, with units of mol/L (also written M). The moles of solute come from its mass divided by its molar mass, moles = mass ÷ molar mass, so the full relationship ties together mass, molar mass, volume and concentration. This calculator solves for any one of molarity, mass of solute, solution volume or molar mass, and accepts the volume in litres or millilitres.

As a worked example, dissolving 58.44 g of table salt (NaCl, molar mass ≈ 58.44 g/mol) in enough water to make 1 litre gives 58.44 / 58.44 = 1 mole in 1 L, a 1 M solution. Dissolve 117 g of NaCl instead and you have 2 moles, which in 1 L is a 2 M solution or, in 500 mL, a 4 M solution. Working backwards, to make 250 mL of 0.1 M NaCl you need 0.1 × 0.25 = 0.025 mol, i.e. 0.025 × 58.44 ≈ 1.46 g.

Molarity is the working currency of the lab bench — preparing standard solutions, diluting stock reagents, running titrations and stoichiometry, and mixing buffers all depend on it. Note that it is defined per litre of final solution, not per litre of solvent, so you dissolve the solute and then top up to the target volume rather than adding it to a pre-measured litre of water.

Frequently asked questions

What is molarity?

Molarity (M) is moles of solute per litre of solution. Dissolving 58.44 g of NaCl (1 mole) in 1 litre gives a 1 M solution.

How do I get moles from grams?

Divide the mass in grams by the molar mass in g/mol. 117 g of NaCl is 117 / 58.44 = 2 moles.

How much solute do I need for a target molarity and volume?

Moles needed = molarity × volume in litres, then mass = moles × molar mass. For 250 mL of 0.1 M NaCl that is 0.1 × 0.25 = 0.025 mol, about 1.46 g. Set "solve for" to mass to have the calculator do it.

Is molarity per litre of water or per litre of solution?

Per litre of finished solution. Dissolve the solute, then add solvent up to the mark to reach the target volume — do not simply add it to a full litre of water, which would give a slightly larger volume and lower concentration.

What is the difference between molarity and molality?

Molarity is moles per litre of solution and shifts a little with temperature because volume changes. Molality is moles per kilogram of solvent and is temperature-independent. This tool calculates molarity.

How do I dilute a stock solution?

Use C₁V₁ = C₂V₂: the moles stay constant, so concentration times volume before equals after. To make 1 L of 0.5 M from 2 M stock you need 0.5 × 1 / 2 = 0.25 L of stock topped up to 1 L.

❤️ Love Calculator.Free? Share it

𝕏  X Facebook Reddit
API — use this calculator from code

Call this calculator as a free JSON endpoint — no key required. Send the field values below as query parameters or JSON. Read the full API docs →

Endpoint

GET https://calculator.free/api/v1/molarity/

curl

curl "https://calculator.free/api/v1/molarity/?solve=molarity&mass=58.44&molar_mass=58.44&volume=1"

JavaScript fetch()

const r = await fetch(
  "https://calculator.free/api/v1/molarity/?" + new URLSearchParams({
    "solve": "molarity",
    "mass": "58.44",
    "molar_mass": "58.44",
    "volume": "1"
  }));
const data = await r.json();
console.log(data.results);

Results are estimates for general guidance only, not financial, medical or tax advice.