What Is the mg/L to Molarity Calculator?
This calculator converts a mass concentration expressed in milligrams per liter (mg/L) into a molar concentration, or molarity, expressed in moles per liter (mol/L, also written M). It is widely used in chemistry, biology, environmental science, and pharmacology where measured concentrations are often reported as mg/L (equivalent to parts per million in dilute water solutions) but reactions and calculations require molarity.
How to Use It
Enter two values: the concentration in mg/L and the molar mass (molecular weight) of the substance in grams per mole (g/mol). The calculator returns the molarity in mol/L, along with convenient millimolar (mM) and micromolar (µM) equivalents.
The Formula Explained
The conversion is based on the definition of molarity: moles of solute per liter of solution. Since 1 mg = 0.001 g, dividing the mg/L value by 1000 converts it to g/L. Dividing by the molar mass (g/mol) then yields mol/L:
$$\text{M} = \frac{\text{mg/L}}{1000 \times \text{MW}}$$
Worked Example
Suppose you have a sodium chloride (NaCl) solution at 100 mg/L. The molar mass of NaCl is 58.44 g/mol. Then $$\text{M} = \frac{100}{1000 \times 58.44} = \frac{100}{58440} \approx 0.001711 \text{ mol/L},$$ or about 1.711 mM. This means each liter contains roughly 1.711 millimoles of NaCl.
Molar Masses of Common Compounds
Molar mass (g/mol) is the sum of the standard atomic masses of all atoms in the formula. The values below are rounded to two decimals and are suitable for routine concentration conversions.
| Substance | Formula | Molar mass (g/mol) |
|---|---|---|
| Sodium chloride | NaCl | 58.44 |
| Potassium chloride | KCl | 74.55 |
| Glucose | C6H12O6 | 180.16 |
| Calcium carbonate | CaCO3 | 100.09 |
| Sodium hydroxide | NaOH | 40.00 |
| Hydrogen chloride | HCl | 36.46 |
| Sulfuric acid | H2SO4 | 98.08 |
| Sodium bicarbonate | NaHCO3 | 84.01 |
| Ammonium ion | NH4+ | 18.04 |
| Nitrate ion | NO3- | 62.00 |
| Calcium chloride | CaCl2 | 110.98 |
| Magnesium sulfate (anhydrous) | MgSO4 | 120.37 |
| Sucrose | C12H22O11 | 342.30 |
| Urea | CH4N2O | 60.06 |
Note: hydrated salts (for example MgSO4·7H2O) have a higher molar mass than the anhydrous forms listed here, so use the molar mass of the exact form you weighed.
Example Conversions for Common Substances
Each row uses \(M = \frac{\text{mg/L}}{1000 \times MW}\). The first four substances are compared at the same mass concentration of 100 mg/L; the last row shows nitrate at 10 mg/L. The same mass concentration gives very different molarities because molar masses differ.
| Substance | Concentration (mg/L) | Molar mass (g/mol) | Molarity (M) | mM | µM |
|---|---|---|---|---|---|
| NaCl | 100 | 58.44 | 0.001711 | 1.711 | 1711 |
| Glucose | 100 | 180.16 | 0.0005551 | 0.5551 | 555.1 |
| CaCO3 | 100 | 100.09 | 0.0009991 | 0.9991 | 999.1 |
| NaOH | 100 | 40.00 | 0.002500 | 2.500 | 2500 |
| NO3- | 10 | 62.00 | 0.0001613 | 0.1613 | 161.3 |
Worked substitution for NaCl: \(M = \frac{100}{1000 \times 58.44} = \frac{100}{58440} \approx 0.001711\ \text{mol/L}\), which is 1.711 mM or about 1711 µM.
Concentration Unit Equivalents
| Unit | Equivalent |
|---|---|
| 1 M (mol/L) | 1000 mM |
| 1 M | 1,000,000 µM |
| 1 M | 109 nM |
| 1 mM | 1000 µM |
| 1 g/L | 1000 mg/L |
| 1 mg/L | 1000 µg/L |
| 1 mg/L | ≈ 1 ppm (by mass) in dilute aqueous solution, where the density is about 1 g/mL |
How to convert between them
- mg/L to mol/L: divide by 1000 to get g/L, then divide by the molar mass in g/mol: \(M = \frac{\text{mg/L}}{1000 \times MW}\).
- mol/L to mg/L: multiply by the molar mass and by 1000: \(\text{mg/L} = M \times MW \times 1000\).
- M to mM or µM: multiply by 1000 for mM, or by 1,000,000 for µM.
- mg/L to ppm: the values are numerically equal only for dilute aqueous solutions near 1 g/mL. For concentrated or non-aqueous solutions, do not assume this.
FAQ
Is mg/L the same as ppm? In dilute aqueous solutions where density ≈ 1 g/mL, mg/L is numerically equal to ppm (mg per kg).
What molar mass should I use? Use the molecular weight of the exact compound, including water of hydration if applicable, in g/mol.
How do I go back from molarity to mg/L? Multiply molarity by 1000 and by the molar mass: \(\text{mg/L} = \text{M} \times 1000 \times \text{MW}\).