Unit Converter
Mole Fraction Calculator
Calculate the mole fraction of a solute and a solvent from amounts in moles or from masses and molar masses.
Mole Fraction Calculator examples
These worked cases run sodium chloride in water, given in moles and in grams, through this calculator.
| Input | Expected result |
|---|---|
| 1 mol solute, 55.5 mol water | x(solute) 0.0177 · x(water) 0.9823 |
| 58.44 g NaCl, 1,000 g water | x(NaCl) 0.0177 |
| Total amount | 56.5 mol |
Supported units & limits
Handles two components, a solute and a solvent. Amounts must be greater than 0 and at most 10¹². Molar masses in g/mol are needed only when an amount is in grams, and are inputs. Dissociation is not applied, so a salt that dissolves into ions is counted as one component. Mole fractions are not concentrations in mol/L and have no temperature dependence. Results use floating-point arithmetic and rounding follows the chosen precision.
Common mistakes
A mole fraction uses moles of both components, not mass. A 10 % solution by mass is not x = 0.1. The two mole fractions must add to 1, so a mixture of more than two components needs the sum of all components. Use the molar mass of the exact species. A mole fraction is dimensionless, so “ppm by moles” differs from “ppm by mass”. A salt that dissociates is still counted as one component in this calculator; count the ions yourself if your model needs them.
Privacy
Conversions run in your browser. This site does not upload or store the values you enter. We use Google Analytics (through Google Tag Manager) to count page visits, and Microsoft Clarity to see how pages are used, such as clicks and scrolling; both may set cookies, and Clarity is set to mask text on the page. The hosting server may keep standard access logs when you load a page.
Conversion guide
Convert everything to moles first
Enter each component either as moles or as a mass with its molar mass. The tool converts to moles and divides by the total. For more than two components, add all of the other amounts into the second field.
Mole Fraction Calculator FAQ
How do I calculate mole fraction?
Divide the moles of the component by the total moles of all components. The tool turns masses into moles first.
Is mole fraction the same as mass fraction?
No. Mole fraction counts molecules and mass fraction counts mass. They differ unless the molar masses are equal.
Do the mole fractions always add to 1?
Yes, for a complete mixture. This tool shows both components, which add to exactly 1.