Calculate percent composition

Break a chemical formula into each element’s percentage by mass.

freeworks offlinenothing uploaded
ToolPercent Composition Calculator
Input
Output
Put this on your own site

The frame below runs the same code as this page, in the reader's own browser. Nothing is sent to us, and nothing is sent to you.

Pick a dark background and the text and panels follow it, so the frame stays readable on a dark page.

Preview

How it works

The parser expands counts, each contribution is count × atomic weight, and contribution divided by total formula mass gives mass percentage. Rounded display values therefore sum approximately to 100%.

  • Standard atomic weights are used.
  • Percentages are rounded only for display.

Worked example

Water
H2O split into hydrogen and oxygen by mass
Input
											H2O
										
Output
												Molar mass: 18.015
Breakdown: O: 88.81%, H: 11.19%
											

When to use this

Students break water into element percentages, materials reports compare composition, and assay checks compare formula with measured mass.

Edge cases

  • Parenthesized groups contribute every repeated atom.
  • Rounded visible percentages can sum to 99.99% or 100.01%.
  • Isotope-enriched samples can differ from standard-weight results.

References