StatGardenREF. DESK
Calculators/Chemistry/Mole fraction of a mixture
Chemistry

Mole fraction of a mixture calculator

Fraction of the total moles in a mixture contributed by each component.

Published 8 August 2026 · Updated 25 September 2026

What this calculator does

Mole fraction is the moles of one component divided by the total moles in the mixture. With 2.5 moles of one substance and 0.5 of another, the fractions are 0.8333 and 0.1667.

Because every fraction is a share of the same total, they always sum to exactly 1. That makes mole fraction a natural way to express composition, and it is the quantity that appears in Raoult law, Dalton law of partial pressures and most solution thermodynamics.

The formula

FormulaXᵢ = nᵢ / (n₁ + n₂ + … + nₖ)

Each component moles are divided by the sum of all moles. The result is dimensionless and independent of the units used, as long as all components are expressed the same way. Mole fraction is not the same as mass fraction, and the two differ whenever the components have different molar masses.

TermMeaning
Mole fraction (X)Moles of a component over total moles. Dimensionless, summing to 1.
Mass fractionThe mass-based equivalent, which differs whenever molar masses differ.
Mole percentMole fraction times 100.
Dalton lawPartial pressure equals mole fraction times total pressure, for ideal gases.

The inputs explained

FieldWhat to enter
Moles of each component (comma-separated)Moles of each component, comma separated. Any consistent unit works, since the units cancel.

When to use it

Calculating partial pressures

Each gas partial pressure is its mole fraction times the total pressure.

Applying Raoult law

The vapour pressure of a solution depends on the mole fraction of the solvent.

Expressing alloy or mixture composition

Atomic composition is naturally a mole fraction, even where the material is sold by mass.

Worked examples

Every figure in the tables below is produced by this page’s own calculator at build time, so the numbers and the tool always agree. Select any row to load that scenario.

How do the fractions divide up?

Several two-component mixtures with different proportions.

Two-component mixtures
Moles of each componentMole fraction of component 1Mole fraction of component 2Total moles
1, 10.50000.50002.000 mol
3, 10.75000.25004.000 mol
2.5, 0.50.83330.16673.000 mol
0.1, 9.90.01000.990010.000 mol
The two fractions always sum to exactly 1, which is the useful check on any mole fraction calculation. An equal mixture gives 0.5 each, and the last row shows a component present at 1% of the total.

Questions

Do mole fractions always add to 1?

Yes, by construction, since each is a share of the same total. This makes a useful check: if your fractions do not sum to 1, something has been miscounted or a component has been omitted from the total.

What is the difference between mole fraction and mass fraction?

One counts particles and the other counts mass. They coincide only when all components have the same molar mass. A mixture that is 50% by mass of hydrogen and oxygen is overwhelmingly hydrogen by mole fraction, because hydrogen molecules are sixteen times lighter.

Can mole fraction exceed 1?

No. Each fraction lies between 0 and 1 because the numerator is part of the denominator. A value above 1 means an arithmetic error, usually a component left out of the total or a unit mismatch between components.

Why use mole fraction rather than concentration?

Because it is dimensionless and independent of temperature and volume, and because the laws of solution thermodynamics are expressed in it. Raoult law, Dalton law and colligative property relationships all take mole fraction rather than molarity.

For gas mixtures, see the partial pressure calculator. For vapour pressure of a solution, see the Raoult’s law calculator.