Home/Calculators/Chemistry/Percent Composition Calculator

Percent Composition Calculator

Find what percent of a compound's mass comes from one element.

percent-composition-calculator
Result
—
In summary: Percent composition is the element's mass divided by the compound's mass, times 100: (element mass ÷ compound mass) × 100. With 12 g of carbon in 44 g of CO₂, that is (12 ÷ 44) × 100 = 27.27%.

Percent composition formula

The percent composition of an element in a compound is (element mass ÷ compound mass) × 100. Use the mass of the element contributed by all its atoms in one formula unit, divided by the molar mass of the whole compound. The percentages of all elements in a compound add to 100%. To work out the masses themselves, start from the mole fraction calculator or a molar-mass table.

How to use this calculator

Enter the total mass contributed by the element of interest and the mass of the whole compound, both in the same unit (grams here, or g/mol). The calculator divides, multiplies by 100, and shows the result as a percentage. A zero compound mass is rejected. The atomic masses in the formula are themselves weighted averages, as the average atomic mass calculator shows.

Worked example

Carbon dioxide (CO₂) has a molar mass of 44 g/mol, of which carbon contributes 12 g/mol. Percent carbon = (12 ÷ 44) × 100 = 27.27%, so the remaining 72.73% is oxygen. For a single component of a mixture rather than a compound, use the mass percent calculator.

Frequently asked questions

What is percent composition?
Percent composition is the percentage by mass that each element contributes to a compound, found by dividing the element's mass by the compound's mass and multiplying by 100.
How do I get the element mass for a compound?
Multiply the element's atomic mass by the number of its atoms in the formula. For CO2, oxygen contributes 2 x 16 = 32 g/mol.
Should the percentages add to 100?
Yes. Adding the percent composition of every element in a compound should total 100%, allowing for small rounding.
Can I use molar masses instead of grams?
Yes. Because it is a ratio, using g/mol values gives the same percentage as using grams of an actual sample.
How is percent composition different from percent yield?
Percent composition describes what a compound is made of by mass, and is fixed for a given formula. Percent yield describes how much product a reaction actually gave compared with theory, and changes from run to run.
How this tool works

The formula behind this tool is written out in full in the sections above, so you can check the maths yourself. Every calculator on Calculorium is verified against worked examples with automated tests before it is published, and pages are reviewed as formulas or standards change. Nothing you type is sent anywhere — the calculation runs entirely in your browser. Read how we build and check these tools.

Last updated: July 27, 2026 · Calculations run in your browser. Estimates for information only.