On this page
Formula
M = n ÷ V, with n = m ÷ M_w
- M
- molarity (amount concentration), moles of solute per liter of solution, mol/L
- n
- amount of solute in moles
- V
- volume of the finished solution in liters
- m
- mass of solute in grams
- M_w
- molar mass (molecular weight) of the solute in g/mol
What molarity is
Molarity is the most common way chemists describe how concentrated a solution is. It is the amount of dissolved substance (the solute), in moles, per liter of the whole solution:
M = n ÷ V
A 1 M (one molar) solution contains 1 mole of solute in every liter. Because a mole is a fixed number of particles (about 6.022 × 10²³), molarity tells you how many molecules or formula units are in a given volume, which is what matters when substances react. The SI name is amount-of-substance concentration, and NIST recommends writing the unit as mol/L rather than M, but “molarity” and “M” remain standard in teaching labs and textbooks.
How to use the molarity calculator
The molarity calculator has three modes:
- Find molarity. Enter the amount of solute (grams, milligrams, moles or millimoles), the molar mass if you entered a mass, and the final volume of solution. The result is shown in M, mM, µM or nM, with the mass concentration in g/L.
- Find mass / moles. Enter the target molarity and volume. You get the moles of solute, and if you add the molar mass, the grams to weigh out. This is the mode for preparing a solution.
- Find volume. Enter how much solute you have and the molarity you want. The result is the volume of solution you can make.
Each answer includes the working, so you can copy it into a lab notebook.
How to calculate molarity by hand
You dissolve 14.61 g of sodium chloride and make the solution up to 250 mL.
- Convert grams to moles: n = 14.61 g ÷ 58.44 g/mol = 0.25 mol.
- Convert the volume to liters: 250 mL = 0.25 L.
- Divide: M = 0.25 mol ÷ 0.25 L = 1.00 M.
How many grams to weigh out
Rearranging gives the formula used most at the bench:
mass (g) = molarity (mol/L) × volume (L) × molar mass (g/mol)
For 500 mL of 0.5 M potassium chloride (74.55 g/mol): 0.5 × 0.5 × 74.55 = 18.64 g. Dissolve it in less than 500 mL of water, then add water up to the 500 mL mark.
Finding the molar mass
Add up the atomic weights of every atom in the formula, using the IUPAC standard atomic weights. For glucose, C₆H₁₂O₆: 6 × 12.011 + 12 × 1.008 + 6 × 15.999 = 180.156 g/mol. Supplier labels give the formula weight of the exact product, including any water of crystallization, so use that number when you have it.
Grams for common lab solutions
Grams needed for 1 L of solution. For other volumes, multiply by the volume in liters; for other molarities, scale in proportion.
| Solute | Formula | Molar mass (g/mol) | 0.1 M | 1 M |
|---|---|---|---|---|
| Sodium hydroxide | NaOH | 40.00 | 4 g | 40 g |
| Sodium chloride | NaCl | 58.44 | 5.844 g | 58.44 g |
| Potassium chloride | KCl | 74.55 | 7.455 g | 74.55 g |
| Sodium bicarbonate | NaHCO₃ | 84.01 | 8.401 g | 84.01 g |
| Calcium chloride (anhydrous) | CaCl₂ | 110.98 | 11.098 g | 110.98 g |
| Tris base | C₄H₁₁NO₃ | 121.14 | 12.114 g | 121.14 g |
| Glucose | C₆H₁₂O₆ | 180.16 | 18.016 g | 180.16 g |
| Sucrose | C₁₂H₂₂O₁₁ | 342.30 | 34.23 g | 342.3 g |
Molar masses are calculated from IUPAC standard atomic weights and rounded to two decimals.
Molarity vs molality and other concentration units
- Molarity (M): mol of solute per liter of solution. Easy to use with volumetric glassware.
- Molality (m): mol of solute per kilogram of solvent. Used for boiling-point and freezing-point calculations because it doesn’t change with temperature.
- Mass concentration (g/L or mg/mL): grams per liter. Multiply molarity by molar mass to convert.
- Percent w/v: grams per 100 mL. A 1% w/v solution is 10 g/L.
- Normality (N): equivalents per liter, still seen in older acid-base work. For a monoprotic acid such as HCl, normality equals molarity.
Where molarity is used
- Preparing reagents and buffers in teaching, research and clinical labs.
- Titrations, where the molarity of a titrant and the volume used give the moles of analyte.
- Stoichiometry problems that start from a solution volume instead of a mass.
- Biology and pharmacology, where drug and protein concentrations are given in mM, µM or nM.
Once you have a concentrated stock, the dilution calculator works out how much of it to take for a weaker working solution. For gases, where amount depends on pressure and temperature instead of volume of solution, use the ideal gas law calculator.
Common mistakes
- Using the water volume instead of the solution volume. Dissolving 58.44 g of NaCl in 1 L of water gives slightly more than 1 L of solution, so slightly less than 1 M. Always make up to the final volume.
- Forgetting to convert mL to liters. 250 mL is 0.25 L. Dividing by 250 gives an answer 1,000 times too small.
- Using the anhydrous molar mass for a hydrate. CaCl₂·2H₂O weighs about 147 g/mol, not 111 g/mol. Weighing the wrong one gives a solution about 25% weaker than intended.
- Confusing M (molar) with m (molal). The capital letter is per liter of solution; the lowercase italic is per kilogram of solvent.
Glossary
- Solute: the substance being dissolved.
- Solvent: the liquid it dissolves in, usually water.
- Mole: 6.02214076 × 10²³ particles, the SI unit of amount of substance.
- Molar mass: mass of one mole of a substance, in g/mol; numerically equal to the formula weight.
- Volumetric flask: glassware calibrated to hold one exact volume, used to make solutions of accurate molarity.
Worked examples
Molarity of a glucose solution
9 g of glucose (C₆H₁₂O₆, 180.16 g/mol) dissolved and made up to 500 mL.
Inputs (Find molarity): Amount of solute = 9; Amount unit = Grams (g); Molar mass = 180.16 g/mol; Volume of solution = 500; Volume of solution unit = Milliliters
n = m ÷ molar mass = 9 g ÷ 180.16 g/mol = 49.9556 mmol M = n ÷ V = 0.0499556 mol ÷ 0.5 L = 0.0999112 mol/L
Answer: 49.9556 mmol of solute in 500 mL of solution is 99.9112 mM.
Grams of NaOH for a 0.25 M solution
How much sodium hydroxide (40.00 g/mol) to make 2 L of 0.25 M NaOH.
Inputs (Find mass / moles): Molarity = 0.25; Molarity unit = Molar (mol/L); Volume of solution = 2; Volume of solution unit = Liters; Molar mass = 40 g/mol
n = M × V = 0.25 mol/L × 2 L = 500 mmol m = n × molar mass = 0.5 mol × 40 g/mol = 20 g
Answer: Dissolve 20 g (500 mmol) and make up to 2 L for a 0.25 M solution.
Volume from moles
0.15 mol of solute at a target of 0.6 M.
Inputs (Find volume): Amount of solute = 0.15; Amount unit = Moles (mol); Molarity = 0.6; Molarity unit = Molar (mol/L)
V = n ÷ M = 0.15 mol ÷ 0.6 mol/L = 250 mL
Answer: 150 mmol of solute makes 250 mL of 0.6 M solution.
Edge case: micromolar stock without a molar mass
10 mL of a 50 µM solution, with no molar mass entered, so the answer is in moles only.
Inputs (Find mass / moles): Molarity = 50; Molarity unit = Micromolar (µmol/L); Volume of solution = 10; Volume of solution unit = Milliliters
n = M × V = 0.00005 mol/L × 0.01 L = 500 nmol
Answer: 10 mL of 50 µM solution contains 500 nmol of solute.
Assumptions and limitations
- Molarity is moles of solute per liter of final solution, M = n ÷ V. V is the total solution volume after dissolving, not the volume of water you start with.
- When the solute is entered in grams or milligrams, moles are found with n = m ÷ molar mass, using the molar mass you type. Use the formula weight of the exact form you weigh, including any water of hydration.
- The solute is assumed to dissolve completely and not react. Molarity counts formula units, so 1 M NaCl is 1 M in sodium chloride even though it gives 2 mol/L of ions.
- Molarity depends slightly on temperature because liquids expand when warmed. The calculator does not correct for this; prepare solutions near the temperature you use them.
- Units are converted exactly. 1 M = 1 mol/L = 1,000 mM; mass concentration in g/L = molarity × molar mass.
- Results are shown to 6 significant figures, with the unit (M, mM, µM, nM; g, mg, µg) chosen to suit the size of the answer.
Frequently asked questions
How do you calculate molarity?
Divide the moles of solute by the liters of solution, M = n ÷ V. For example, 0.6 mol of solute in 1.5 L of solution is 0.6 ÷ 1.5 = 0.4 M.
How do I calculate molarity from grams?
First convert grams to moles by dividing by the molar mass, then divide by the volume in liters. 2.92 g of NaCl (58.44 g/mol) is 0.05 mol, and in 100 mL (0.1 L) that gives 0.5 M.
How many grams do I need for a solution of a given molarity?
Multiply molarity × volume in liters × molar mass. For 500 mL of 0.5 M KCl (74.55 g/mol) that is 0.5 × 0.5 × 74.55 = 18.64 g, dissolved and then made up to 500 mL.
What is the difference between molarity and molality?
Molarity is moles of solute per liter of solution (mol/L). Molality is moles of solute per kilogram of solvent (mol/kg). Molality does not change with temperature, while molarity changes slightly as the liquid expands or contracts.
What are the units of molarity?
Molarity is measured in moles per liter, written mol/L or M. Smaller concentrations use millimolar (mM, 10⁻³ M), micromolar (µM, 10⁻⁶ M) and nanomolar (nM, 10⁻⁹ M).
How do I convert molarity to mg/mL?
Multiply the molarity by the molar mass to get g/L, which is the same number as mg/mL. A 0.1 M glucose solution (180.16 g/mol) is 18.016 g/L, or 18.016 mg/mL.
How do I find the molarity of concentrated acid from percent and density?
Multiply density (g/mL) × 1,000 × mass fraction, then divide by molar mass. Hydrochloric acid at 37% w/w and 1.19 g/mL is 1,190 × 0.37 ÷ 36.46 ≈ 12.1 M. Check the bottle's own density and assay values.
Sources
- Chemistry 2e, 3.3 Molarity — OpenStax (Rice University). Checked October 10, 2026.
- Standard Atomic Weights — IUPAC Commission on Isotopic Abundances and Atomic Weights (CIAAW). Checked October 10, 2026.
- NIST Guide to the SI, Chapter 8: Comments on Some Quantities and Their Units — National Institute of Standards and Technology. Checked October 10, 2026.