Molarity Calculator - Mass, Molar Mass, and Volume to Moles Per Liter

Use this molarity calculator to convert grams of solute and solution volume into molar concentration, or to work backward from a target molarity to the mass or volume required.

Updated: July 8, 2026 • Free Tool

Molarity Calculator

Choose whether to compute concentration from your ingredients or to find how much mass or volume you need to hit a target molarity.

Mass of the pure solute you dissolve, in grams.

Molar mass of the solute (NaCl is 58.44 g/mol). Use the hydrated value for hydrated salts.

Volume of the FINAL solution, not the solvent you add.

Milliliters are converted to liters internally before the division.

Desired molarity when solving for mass or volume.

Results

Molarity (mol/L)
0
Millimolarity (mmol/L) 0
Mass Concentration (g/L) 0
Moles of Solute 0
Mass Needed (g) 0
Volume Needed (L) 0

What Is a Molarity Calculator?

A molarity calculator gives you the molar concentration of a solution, the number of moles of solute dissolved in each liter of final solution, from the solute mass, its molar mass, and the total solution volume. Chemists write molarity as M and express it in moles per liter (mol/L), so the tool answers the everyday lab question: how concentrated is this solution? You reach for it whenever you prepare a reagent, standardize a titration, or convert between grams on the balance and moles in the flask.

  • Preparing a stock solution: Work out how many grams of salt give a 0.1 M or 1 M stock before you weigh it out.
  • Standardizing a titration: Confirm the exact molarity of an acid or base from the mass you dissolved and the final volume.
  • Converting grams to moles: Turn a weighed mass into moles per liter so you can compare against a recipe stated in mol/L.
  • Reverse recipe planning: Start from a target molarity and solve for the mass or volume you actually need.

Molarity is the concentration unit most general chemistry courses teach first because it ties directly to the stoichiometry of a reaction: one mole of a limiting reactant in one liter of 1 M solution means one mole available for every liter you use.

If your experiment reports concentration in another form, a concentration calculator handles mass concentration, percent concentration, and parts per million alongside molarity, which is handy when you mix units across a procedure.

A concentration calculator handles mass concentration, percent concentration, and parts per million alongside molarity.

How the Molarity Calculator Works

The calculator applies the definition of molarity: divide moles of solute by liters of solution. Because balances read grams, it first turns mass into moles by dividing by the molar mass, then divides by the solution volume expressed in liters.

M = m / (M_m x V) where M = molarity (mol/L), m = mass (g), M_m = molar mass (g/mol), V = solution volume (L)
  • m (solute mass): Mass of the pure solute in grams, read from the balance.
  • M_m (molar mass): Grams per mole of the solute; for hydrated salts use the hydrated value.
  • V (solution volume): Volume of the final solution in liters; milliliters are divided by 1000 first.
  • M (molarity): Result in moles per liter, the molar concentration.

In reverse mode the same relationship is rearranged: mass = M x V x M_m and volume = moles / M, so the calculator can tell you how much to weigh or how much to dilute to hit a target molarity.

When you only know the molar mass and mass, a mole and molar mass calculator converts grams to moles before you divide by volume, removing a step from manual prep.

Sodium chloride, 5.844 g in 500 mL

Enter 5.844 g of NaCl, molar mass 58.44 g/mol, and a final volume of 500 mL.

Moles = 5.844 / 58.44 = 0.1000 mol. Volume = 500 / 1000 = 0.500 L. Molarity = 0.1000 / 0.500 = 0.200 mol/L.

Molarity = 0.200 M (200 mmol/L).

Every liter of this solution contains 0.200 mol of NaCl, matching a 5.844 g dose in a half liter.

According to OpenStax Chemistry 2e.

Use a mole and molar mass calculator to convert grams to moles and look up the molar mass before you divide by volume.

Key Concepts Explained

A few related ideas keep molarity results meaningful, especially once you compare it with other concentration measures.

Moles versus mass

Moles count particles; mass counts grams. Dividing mass by molar mass gives moles, and only moles divided by liters yields molarity.

Solution volume versus solvent volume

Molarity uses the FINAL solution volume, not the volume of solvent you poured in, because the solute adds volume when it dissolves.

Molarity versus molality

Molarity divides by solution volume and changes with temperature, while molality divides by solvent mass in kilograms and stays fixed with temperature.

Millimolarity

Millimolarity is molarity times 1000 (mmol/L) and is the natural unit for dilute biological and physiological buffers.

The distinction between solution volume and solvent volume is the most common source of a wrong molarity in the lab, so always fill to the mark in a volumetric flask rather than adding a fixed solvent volume.

After you change concentration by adding solvent, a dilution formula calculator works out the new molarity from the stock molarity, stock volume, and final volume.

When you lower molarity by adding solvent, a dilution formula calculator works out the new concentration after mixing.

How to Use This Calculator

Follow these steps in the molarity calculator to go from a weighed sample to a reliable molar concentration, or from a target molarity to the amount you need.

  1. 1 Pick a mode: Choose whether to find molarity from mass, molar mass, and volume, or to solve for the mass or volume at a target molarity.
  2. 2 Enter the solute mass: Type the mass of pure solute in grams; leave it at zero in mass or volume solve modes.
  3. 3 Enter the molar mass: Add the solute molar mass in g/mol (use the hydrated value for hydrated salts), or look it up from the formula.
  4. 4 Enter the solution volume: Enter the FINAL solution volume and select mL or L; milliliters are converted to liters automatically.
  5. 5 Read the results: The tool returns molarity, millimolarity, mass concentration in g/L, and the moles of solute.
  6. 6 Solve backward if needed: For a target molarity, switch mode and read the mass needed in grams or the volume needed in liters.

To make 250 mL of 0.5 M NaCl, set mode to 'mass', molar mass 58.44 g/mol, volume 250 mL, and target 0.5 M. The calculator returns 7.305 g of NaCl to dissolve and dilute to the mark.

If your recipe lists a weight percent instead of mol/L, a percent solution calculator converts it to a mass-based value you can compare.

Benefits of Using This Calculator

This molarity calculator removes the manual unit juggling that makes solution prep error prone.

  • Fewer unit mistakes: It converts mL to L and grams to moles internally, so you avoid the most common slip of forgetting to divide volume by 1000.
  • Faster recipe scaling: Reverse mode gives the exact mass or volume for any target molarity, which speeds up scaling a stock solution up or down.
  • Clear secondary values: Moles, millimolarity, and mass concentration appear together, so you can report the result in whichever unit your protocol expects.
  • Consistent lab records: Recording molarity from a single method keeps your notebooks and SOPs comparable across technicians and batches.
  • Teaching aid: Worked steps show students where the 1000 factor and the molar mass division happen, which builds intuition for the formula.

Factors That Affect Your Results

Molarity is a measured quantity, so several practical factors decide whether the number you calculate matches the real solution.

Final volume accuracy

Reading the meniscus at eye level in a calibrated volumetric flask sets how close the real volume is to the entered value.

Molar mass choice

Using the anhydrous instead of the hydrated molar mass, or the wrong formula, shifts the moles and therefore the molarity.

Temperature

Because molarity divides by solution volume and liquids expand when warmed, molarity drops slightly as temperature rises.

Purity and hydration

Impurities and water of crystallization change the effective mass of analyte, so weigh-and-dissolve molarity is an approximation for impure reagents.

  • The tool assumes the entered mass is the pure analyte; for impure or hydrated solids, correct the mass by purity or use the hydrated molar mass first.
  • It reports molarity from the values you enter and does not account for incomplete dissolution or density-driven volume changes of the real solution.

For most teaching and routine lab work these effects are small, but for quantitative analysis at high precision you should standardize the solution by titration rather than trust a calculated molarity.

Temperature effects matter because, as discussed in analytical references, molar concentration depends on solution volume, so it shifts when temperature changes the volume.

According to LibreTexts Analytical Chemistry 2.1.

Molarity calculator converting solute mass, molar mass, and solution volume into molar concentration in mol per liter
Molarity calculator converting solute mass, molar mass, and solution volume into molar concentration in mol per liter

Frequently Asked Questions

Q: What is molarity in chemistry?

A: Molarity is the concentration of a solution expressed as moles of solute per liter of final solution, written in mol/L or M. It tells you how many moles of a substance are present in each liter of solution.

Q: How do you calculate molarity from grams?

A: First divide the grams of solute by its molar mass to get moles, then divide those moles by the solution volume in liters. In one line: molarity = mass / (molar mass x volume in liters).

Q: What is the molarity formula?

A: The formula is M = n / V, where n is moles of solute and V is liters of solution. Since n = mass / molar mass, it expands to M = mass / (molar mass x volume in liters).

Q: Does molarity change with temperature?

A: Yes. Molarity divides by solution volume, and liquids expand as they warm, so a solution's molarity decreases slightly at higher temperature even though the amount of solute is unchanged.

Q: Molarity vs molality: what is the difference?

A: Molarity divides moles of solute by liters of solution and varies with temperature, while molality divides moles of solute by kilograms of solvent and stays constant with temperature.

Q: How do I find the mass needed for a target molarity?

A: Rearrange the formula to mass = molarity x volume in liters x molar mass. For 250 mL of 0.5 M NaCl you need 0.5 x 0.250 x 58.44 = 7.305 g, which this calculator returns in mass-solve mode.