Molarity Calculator
Enter the molar mass, then any two of mass, volume, or molarity.
How to Use
Enter the molar mass of your solute in grams per mole (look this up from the periodic table or a compound's molecular formula, for example, sodium chloride, NaCl, is 58.44 g/mol). Then enter any two of mass, volume, or molarity, and the third fills in automatically. This mirrors the two most common lab tasks: figuring out the concentration of a solution you've already made, or figuring out how much solute to weigh out to hit a target concentration in a known volume.
The Molarity Formula
Molarity (M) is defined as moles of solute per liter of solution: M = n / V, where moles (n) is mass divided by molar mass: n = mass / molar mass. This calculator combines both formulas so you can work directly from mass and volume, the values you actually measure in a lab, instead of calculating moles by hand first.
A Worked Example: Finding the Molarity of a Saline Solution
Suppose you dissolve 10 grams of sodium chloride (NaCl, molar mass 58.44 g/mol) in enough water to make 500 mL of solution. First convert mass to moles: 10 ÷ 58.44 = 0.1711 mol. Then divide by volume in liters: 0.1711 ÷ 0.5 = 0.3422 mol/L. The resulting solution is approximately 0.342 M, matching the default placeholder values shown in this calculator's fields.
A Worked Example: Preparing a Target Molarity
Now go the other direction: suppose a lab procedure calls for 250 mL of 0.1 M sodium hydroxide (NaOH, molar mass 40 g/mol). First find the moles needed: 0.1 mol/L × 0.25 L = 0.025 mol. Then convert moles to mass: 0.025 × 40 = 1 gram. Weighing out exactly 1 gram of NaOH and dissolving it in enough water to reach a final volume of 250 mL produces the target 0.1 M solution. This mass-from-target-molarity direction is what most students and lab technicians actually need most often when preparing reagents from scratch.
Molarity vs Other Concentration Units
Molarity is the most common concentration unit in general and analytical chemistry, but it isn't the only one. Molality (moles of solute per kilogram of solvent, not solution) is preferred for calculations involving temperature changes, since mass doesn't expand or contract with heat the way volume does. Percent weight/volume (% w/v) and parts per million (ppm) are common in biology, pharmacology, and environmental testing, especially for very dilute solutions where molarity would produce inconveniently small numbers. Converting between these units requires knowing the solute's molar mass and, for molality or density-based units, the solution's density, information this molarity-specific calculator doesn't ask for since it isn't needed for the M = n/V relationship.
Dilutions: Using Molarity with M1V1 = M2V2
A closely related lab task is diluting a concentrated stock solution down to a lower working concentration, using the dilution equation M1V1 = M2V2, where M1 and V1 describe the stock solution and M2 and V2 describe the target. For example, diluting a 2 M stock down to 500 mL of 0.5 M solution requires V1 = (M2 × V2) / M1 = (0.5 × 500) / 2 = 125 mL of stock solution, topped up with solvent to the full 500 mL. This calculator handles the mass-volume-molarity relationship for a single solution; the dilution equation is the tool to reach for once you already have a stock solution of known molarity on hand.
Common Molar Masses for Reference
A few frequently used molar masses come up often enough to be worth knowing without looking them up each time: water (H2O) is 18.02 g/mol, sodium chloride (NaCl) is 58.44 g/mol, sodium hydroxide (NaOH) is 40.00 g/mol, hydrochloric acid (HCl) is 36.46 g/mol, and glucose (C6H12O6) is 180.16 g/mol. For compounds outside this short list, adding up each element's atomic weight from a periodic table, multiplied by how many atoms of that element appear in the formula, always gives the correct molar mass.
Why Molarity Matters in the Lab
Molarity matters because chemical reactions occur based on the ratio of molecules or ions reacting, not the ratio of masses. Two solutions with identical mass concentrations (grams per liter) of different compounds can contain very different numbers of moles, and therefore react completely differently in a titration, a synthesis, or a biological assay. Expressing concentration in moles per liter lets chemists directly compare and combine solutions based on the actual number of reacting particles present, which is why molarity, rather than a simpler mass-based unit, is the standard for stoichiometric calculations throughout chemistry.
Molarity in Everyday Life and Industry
Molarity calculations extend well beyond the classroom and research lab. Water treatment facilities use molarity to precisely dose chlorine and other disinfectants into municipal water supplies. Pharmaceutical manufacturing relies on accurate molarity to ensure a medication delivers the correct dose of active ingredient per volume. Winemakers and brewers track the molarity of sugars and acids to predict fermentation behavior and final product quality. Even swimming pool maintenance involves a simplified version of the same concept, dosing chemicals based on pool volume to reach a target concentration. In every case, the same underlying math, moles of active substance per liter of solution, is what determines whether a dose is effective, wasteful, or unsafe.
Practical Lab Tips for Accurate Molarity
A few habits meaningfully improve the accuracy of a molarity calculation in practice. Use a volumetric flask rather than a beaker or graduated cylinder when a precise final volume matters, volumetric flasks are calibrated far more precisely for a single target volume. Dissolve the solute in slightly less than the target volume of solvent first, then add solvent to reach the final calibration mark, rather than adding a fixed volume of solvent to a fixed mass of solute, since dissolving a solid can itself change the total solution volume slightly. Weigh solids on a calibrated analytical balance rather than estimating, and double-check the molar mass calculation for the specific chemical form on hand, anhydrous versus hydrate versions of the same compound have meaningfully different molar masses, as covered in the FAQ below.
Molarity, Moles, and Avogadro's Number
Behind every molarity calculation is the mole itself, a unit representing a fixed number of particles, defined as approximately 6.022 × 10²³ (Avogadro's number). A 1 M solution contains one mole, roughly 602 sextillion individual molecules or ions, of solute per liter. This is why molarity is such a useful bridge between the macroscopic world of grams and milliliters that you actually measure on a bench, and the microscopic world of individual reacting molecules that determines how a chemical reaction actually proceeds. Two reagents combined in a 1:1 molar ratio contain equal numbers of reacting particles, even if their masses differ enormously, which is the entire basis for stoichiometric calculations in chemical equations.
Safety Considerations When Preparing Solutions
Calculating the correct mass and volume is only part of preparing a solution safely. Always check a chemical's safety data sheet before handling it, some compounds generate significant heat when dissolving (an exothermic process, notably concentrated acids and strong bases), and should be added slowly to solvent rather than the reverse to avoid splashing or a dangerous temperature spike. Appropriate personal protective equipment, gloves and eye protection at minimum, should be worn whenever handling laboratory chemicals, regardless of how dilute the final target concentration is, since the concentrated starting material is often far more hazardous than the finished solution.
Common Mistakes in Molarity Calculations
Forgetting to convert milliliters to liters. The molarity formula is defined in moles per liter, so a volume entered in milliliters must be divided by 1,000 before use, a step this calculator handles automatically but is a frequent manual arithmetic error otherwise.
Using the wrong molar mass for a hydrate or a compound with water of crystallization. Many common lab chemicals, like copper sulfate pentahydrate, include water molecules as part of their solid crystal structure, and that water's mass must be included in the molar mass used for the calculation, not just the "active" compound's mass alone.
Confusing molarity with concentration by mass. A solution labeled "10% NaCl" describes a mass-based percentage, not a molarity, and the two aren't interchangeable without knowing the solution's density and doing an additional conversion step.
Frequently Asked Questions
Where do I find the molar mass of a compound?
Add up the atomic weights of every atom in the compound's formula using a periodic table. Many lab reference sites and safety data sheets also list a compound's molar mass directly.
Why is volume in milliliters but molarity in mol/L?
Milliliters match how lab glassware is typically marked (graduated cylinders, volumetric flasks), while molarity is conventionally expressed per liter, the calculator converts between them automatically.
Does this account for solution density or temperature?
No, this calculator uses the standard molarity formula based on solute mass and solution volume only. For most dilute aqueous solutions at room temperature this is accurate enough for general lab and classroom use.
How is molarity different from molality?
Molarity (M) is moles of solute per liter of solution. Molality (m) is moles of solute per kilogram of solvent. They're close for dilute aqueous solutions but diverge for concentrated solutions or when temperature changes, since volume expands with heat but mass does not.
How do I calculate a dilution using molarity?
Use the dilution equation M1V1 = M2V2, where M1 and V1 are the concentration and volume of your starting (stock) solution, and M2 and V2 are the target concentration and volume. Solve for whichever variable you need.
What if my compound is a hydrate, like CuSO4·5H2O?
Include the water of hydration in the molar mass calculation. Copper sulfate pentahydrate's molar mass includes both the CuSO4 (159.6 g/mol) and the five water molecules (5 × 18.02 g/mol), for a total of about 249.7 g/mol, not just the anhydrous CuSO4 value.