Mole Fraction Calculator
Result
Mole fraction of A
- Mole fraction of B
- 0.60000
- Mole fraction of C
- 0.00000
- Mole percent of A
- 40.000%
- Mole percent of B
- 60.000%
- Mole percent of C
- 0.000%
Give this mole fraction calculator the moles of each component and it reports what share of the mixture each one is, by particle count rather than by weight. The fractions add to one, the mole percent beside each one adds to 100, and the third component is optional because most mixtures are two things rather than three. Units do not change the answer: two moles against three, or two thousand millimoles against three thousand, give the same 0.4 and 0.6, because a mole fraction is a ratio and the units cancel. That is also why the page can take whatever unit your notes are already in instead of making you convert to moles first.
Mole fraction and mole percent for five mixtures
| Moles of A | Moles of B | Mole fraction of A | Mole percent of A |
|---|---|---|---|
| 1 | 1 | 0.50000 | 50.000% |
| 1 | 3 | 0.25000 | 25.000% |
| 2 | 3 | 0.40000 | 40.000% |
| 3 | 1 | 0.75000 | 75.000% |
| 1 | 9 | 0.10000 | 10.000% |
The last two columns are computed by the same arithmetic the calculator uses, so typing a pair of amounts from this table reproduces the figures printed beside them. The rows are chosen to show the shape of the answer rather than to cover chemistry: the first is an even split, the second and third put the fraction at a third and at two thirds, and the last two are extreme enough that the five-decimal precision is what keeps the answer off zero. Note that B's fraction is not printed — it is 1 minus A's, and in a two-component mixture that subtraction is the whole of the arithmetic left to do.
Formula
Mole fraction of A = moles of A ÷ (moles of A + moles of B + moles of C), and mole percent = mole fraction × 100
- x_A
- The mole fraction of component A — its share of the total number of particles, a number between 0 and 1. Every mole fraction in a mixture adds up to exactly 1
- n_A
- The moles of component A, the numerator. Millimoles work just as well as moles here, because only the ratio survives
- n_total
- The total moles of every component added together, the denominator. Leave the third component blank and it simply contributes nothing to this sum
- %
- The mole percent, which is the mole fraction multiplied by 100. It is the same quantity in a friendlier notation, not a second measurement
Use it for any mixture described by counts rather than masses — a gas mixture, a solution of two solvents, an alloy, or the vapour above a liquid. Its most common job is partial pressure: in a gas mixture each component's partial pressure is its mole fraction times the total pressure, so a mole fraction of 0.21 in air is what makes oxygen's share of one atmosphere about 21 kilopascals. It is also the concentration unit that does not change with temperature, since it counts particles rather than measuring a volume, which is why molality and mole fraction turn up together in boiling-point and freezing-point work. If what you have is grams rather than moles, convert each one first — the mole fraction formula needs the amounts, not the weights.
Worked examples
Two components, an ordinary mixture
- Add the components: 2 + 3 = 5 moles in total
- A's share: 2 ÷ 5 = 0.4
- B's share: 3 ÷ 5 = 0.6
- As percentages: 0.4 × 100 = 40%, and 0.6 × 100 = 60%
The two fractions add to 1 and the two percentages add to 100, which is the check that the denominator was the total and not one of the components. The third component was left blank and contributes nothing — its fraction reads 0, which is the true statement that there is no C in this mixture. Had the amounts been written as 2000 and 3000 millimoles the answer would be identical, because the units cancel in the division.
Three components, and one of them is dominant
- Total: 1 + 2 + 3 = 6 moles
- A: 1 ÷ 6 = 0.16667 to five decimals
- B: 2 ÷ 6 = 0.33333
- C: 3 ÷ 6 = 0.5, or 50%
This is the case that shows why the fractions are quoted to five decimals: 1/6 does not terminate, and 0.16667 is as close as a displayed number gets. The percentages still add to 100 (16.667 + 33.333 + 50), which they do exactly here but only to within rounding in general — 1/3 appears twice and is rounded once in each direction.
A trace component, where the rounding matters
- Total: 0.001 + 100 = 100.001 moles
- A: 0.001 ÷ 100.001 = 9.99990 × 10⁻⁶
- Rounded to five decimals: 0.00001
- As a percentage: 0.001%
A tenth of a percent would have vanished here. At five decimals the fraction is 0.00001 rather than 0.00000, and the percentage is 0.001% rather than 0% — both still say the component is there. This is the extreme case the output precision was chosen for: the smallest amount the field accepts divided by the largest, and the answer does not collapse to zero.
Limitations
A mole fraction is only as meaningful as the component list you gave it. Everything not in the three boxes is not in the mixture as far as this page is concerned, so a solution of two solutes in water has to be entered as three components — and the water has to be one of them, because the solvent is most of the particles and leaving it out gives fractions that describe only the solutes. The result is a ratio of particles, which means it says nothing about mass: a mole fraction of 0.5 in a mixture of a light gas and a heavy one is not half the weight. It is also a quantity for a mixture as a whole, so it takes no account of how the components interact — a real solution's volume, boiling point and vapour pressure are not simply the sums of what its parts would do, which is exactly why the mole fraction has to be measured or looked up rather than assumed. Because the arithmetic only divides, an error in any one amount propagates into every fraction; there is no internal check that will catch a miscount. Finally, the third component is optional and the second is not, and that asymmetry is deliberate rather than an oversight: a fraction needs a total, and a mixture of one thing is not a mixture.
Frequently asked questions
- What is a mole fraction?
- The share of a mixture's particles that one component accounts for. If a mixture holds 2 moles of A and 3 moles of B, then A's mole fraction is 2 ÷ 5 = 0.4 and B's is 0.6. Mole fractions have no units, they run from 0 to 1, and every component's share adds to exactly 1 — which is the quickest way to check the arithmetic. The mole percent is the same number multiplied by 100, so 0.4 becomes 40%.
- Does the mole fraction change if I use millimoles instead of moles?
- No. The formula divides one amount by a total of the same kind, so the units cancel — 2000 mmol against 3000 mmol gives the same 0.4 and 0.6 as 2 mol against 3 mol. That is why the fields offer both units and it does not matter which you pick, as long as every component is in the same one. Mixing the two would be the error: 2 mol against 3000 mmol is 2 against 3 moles, not 2 against 3000.
- How do I get a mole fraction from grams?
- Convert each mass to moles first, by dividing it by that substance's molar mass, and then use the formula on the results. Grams cannot be substituted directly, because a mole fraction counts particles and a gram of a heavy substance holds far fewer of them than a gram of a light one — 1 gram of water is 0.0555 mol while 1 gram of ethanol is only 0.0217 mol, so equal weights are nothing like equal fractions. The mole calculator on this site does the mass-to-moles step, and the molecular weight page gives the molar mass if you do not have it.
- What has the mole fraction got to do with partial pressure?
- In a gas mixture, each component's partial pressure is its mole fraction multiplied by the total pressure. Oxygen is 0.2095 of dry air by mole fraction, so at one atmosphere its partial pressure is about 21.2 kilopascals; raise the total pressure and the oxygen partial pressure rises in proportion while the mole fraction stays put. That is the form Dalton's law is usually written in, and it is why a gas mixture's composition is quoted as mole fractions — they are the numbers you multiply pressure by.
- Why is the third component optional but the second one required?
- Because an empty optional box means one specific thing — this mixture does not contain that component — while an empty required box would mean two things at once, and the page cannot tell which. With A and B required, the denominator is always known: leave C blank and the total is A + B, with C's mole fraction reported as 0. Fill A or B with zero and the page refuses instead, because a component you listed as present but gave no amount for makes the total ambiguous. If your mixture genuinely has one component, it is not a mixture and has no mole fraction.
- Why does it report 0.00001 rather than 0 for a trace component?
- Because the fractions are shown to five decimals, which is enough for the smallest ratio the input fields allow: 0.001 mol against 100 mol is 9.99990 × 10⁻⁶, and at five decimals that rounds to 0.00001 rather than collapsing to 0.00000. The mole percent beside it reads 0.001% for the same reason. The number is small, but it is not zero, and a panel that printed 0 would be making a claim about the mixture that is not true.
References
- IUPAC Gold Book — mole fraction — International Union of Pure and Applied Chemistry (IUPAC)
- IUPAC Gold Book — amount fraction — International Union of Pure and Applied Chemistry (IUPAC)
- SI Units — Amount of Substance: the mole — National Institute of Standards and Technology (NIST)