About the Percent Composition Calculator
This percent composition calculator breaks a chemical compound down into the percentage of its mass that comes from each element. Type a formula such as C6H12O6, Ca(OH)2 or CuSO4·5H2O and the calculator counts the atoms, looks up standard atomic weights, and returns the molar mass together with a full element-by-element table and pie chart.
It is useful for chemistry homework on empirical formulas, checking lab results from combustion analysis, comparing fertiliser or supplement ingredients (for example how much of a salt is actually iron or nitrogen) and preparing solutions. Enter a sample mass to see how many grams of each element that amount contains, and name one element to get its mass percent as a single headline number.
Element symbols are case-sensitive — Co is cobalt, CO is carbon monoxide. Brackets, nested groups and hydrate dots are supported. Atomic weights are IUPAC standard (abridged) values, so results may differ from a textbook in the second decimal place.
How to use the percent composition calculator
- 1Type the chemical formula, using correct capital letters for each element.
- 2Optionally enter one element symbol to highlight its mass percent.
- 3Enter a sample mass to see the grams of each element it contains.
- 4Read the percent composition and molar mass.
- 5Use the table and pie chart to compare every element.
Formula and method
For each element, multiply the number of atoms in the formula (n) by its standard atomic weight (Ar) to get that element’s contribution to the molar mass. Add every contribution to get the molar mass M of the compound, then divide each contribution by M and multiply by 100 to get its mass percent. The percentages always add up to 100%.
To find the grams of an element in a sample, multiply the sample mass by the element’s mass fraction. Groups in brackets are multiplied by the subscript after the bracket, and each part of a hydrate is added, so CuSO4·5H2O contains 10 hydrogen and 9 oxygen atoms.
- n
- Number of atoms of the element in one formula unit
- Ar
- Standard atomic weight of the element (g/mol)
- M
- Molar mass of the compound (g/mol)
Worked examples
Glucose, C6H12O6
Carbon contributes 6 × 12.011 = 72.066 g/mol of glucose’s 180.156 g/mol, or 40.00%. Hydrogen is 12.096 ÷ 180.156 = 6.71% and oxygen 95.994 ÷ 180.156 = 53.28%.
Hydrogen in water
Water is 2 × 1.008 + 15.999 = 18.015 g/mol. Hydrogen is 2.016 ÷ 18.015 = 11.19% of the mass, so 50 g of water holds about 5.60 g of hydrogen.
Copper in copper(II) sulfate pentahydrate
The hydrate has 1 Cu, 1 S, 9 O and 10 H, giving 249.68 g/mol. Copper’s 63.546 g/mol is 25.45% of that, so a 25 g sample contains about 6.36 g of copper.
Frequently asked questions
How do you calculate percent composition?+
Multiply each element’s atom count by its atomic mass, add these to get the molar mass, then divide each element’s total by the molar mass and multiply by 100.
Does percent composition always add up to 100%?+
Yes. Because each element’s share is a fraction of the same molar mass, the percentages sum to 100%, apart from tiny rounding differences in the displayed decimals.
What is the difference between percent composition and empirical formula?+
Percent composition gives the mass share of each element. An empirical formula gives the simplest whole-number atom ratio; you can derive it from percent composition by converting each percentage to moles and dividing by the smallest.
Why does oxygen have a higher percentage than hydrogen in glucose?+
Glucose has twice as many hydrogen atoms as oxygen atoms, but each oxygen atom is almost 16 times heavier, so oxygen contributes far more of the total mass (about 53% versus 7%).
How do I enter a hydrate?+
Separate the water of crystallisation with a middle dot (·), asterisk or full stop, for example CuSO4·5H2O or MgSO4*7H2O. The number before H2O multiplies the whole water group.