Empirical Formula Calculator
Determine the empirical formula from elemental mass percentages.
Empirical formula
CH2O
| Element | Mass % | Moles | Ratio |
|---|---|---|---|
| C | 40% | 3.3303 | 1 |
| H | 6.67% | 6.6171 | 2 |
| O | 53.33% | 3.3333 | 1 |
Learn more
What it does
The Empirical Formula Calculator turns elemental mass percentages into the simplest whole-number ratio of atoms in a compound. Those percentages are what combustion analysis, X-ray fluorescence or any elemental composition measurement produces. Enter each element with its percentage and the tool returns the empirical formula together with the intermediate mole values, so the arithmetic can be followed rather than taken on faith. It is used in teaching labs, in compositional analysis, and whenever an unknown needs a formula before its structure can be probed. The calculation runs locally in the browser and nothing is uploaded.
How it works
The method assumes a 100 g sample, which turns each mass percentage into a mass in grams. Every mass is converted to moles by dividing by the atomic weight, using the same IUPAC 2021 standard values as the molar mass tool: C 12.011, H 1.008, N 14.007, O 15.999, Fe 55.845. The mole values are divided by the smallest of them to give a ratio, and the tool then searches for the smallest integer multiplier from 1 to 10 that makes every element ratio a whole number. The acceptance test is strict and applies to all elements at once: every ratio must land within 0.05 of its rounded value at the same multiplier. If the same element is entered on more than one row its percentages are added together before the ratio is taken, so splitting carbon across two rows gives the same formula as entering it once. What comes back is the lowest whole-number ratio, which is not necessarily the molecular formula.
Worked example
Take the classic combustion result of 40.00 percent carbon, 6.71 percent hydrogen and 53.29 percent oxygen. In 100 g that is 40.00 / 12.011 = 3.3303 mol C, 6.71 / 1.008 = 6.6567 mol H and 53.29 / 15.999 = 3.3308 mol O. Dividing through by 3.3303 gives the ratios 1.0000 : 1.9989 : 1.0002, and although the hydrogen ratio falls 0.001 short of 2 it is inside the 0.05 tolerance, so the formula is CH2O. Now try 72.36 percent iron and 27.64 percent oxygen: 72.36 / 55.845 = 1.2957 mol Fe and 27.64 / 15.999 = 1.7276 mol O, a ratio of 1 : 1.3333 that no multiplier fixes at 1. At 3 the ratios become 3 : 4 exactly, and the answer is Fe3O4, the mixed-valence iron oxide whose empirical formula happens to be its full formula. Caffeine teaches the opposite lesson: 49.48 percent C, 5.19 percent H, 28.85 percent N and 16.48 percent O normalise to 4.0000 : 4.9985 : 1.9996 : 1.0000, giving the empirical formula C4H5N2O, while the molecule itself is C8H10N4O2.
When to use it
Use it whenever percentages are what you have rather than a structural formula: combustion analysis, X-ray fluorescence, ICP or EDS quantification, or a textbook problem. It also serves as a check on a proposed formula, because if a molecular formula is a whole-number multiple of the empirical one, the percentages will reproduce it exactly. Three limitations matter. First, the percentages must describe the whole sample. The tool warns only when the total deviates from 100 by more than 0.5, so a missing component at 0.4 percent slips through silently and can tilt a ratio that sits near a rounding boundary. Second, there is a hard ceiling on how far the integers can be stretched. If no multiplier up to 10 makes the ratios whole, the tool prints the plain decimals and flags them, so a result such as C1.5 is not an empirical formula at all; it is a signal that the data are imprecise, that the sample contains something undeclared, or that the measurement is too poor to define a ratio. Third, an unrecognised element symbol is skipped rather than fatal, and the remaining elements are used anyway. That is the most dangerous of the three, because a formula built from a partial composition looks entirely reasonable on screen; symbols are exact, first letter upper case and any second letter lower case, so na is not sodium. Read the warning line above the result before copying anything.
FAQ
- What is an empirical formula?
- It is the simplest whole-number ratio of atoms in a compound. Glucose is C6H12O6 but its empirical formula is CH2O, because 6:12:6 reduces to 1:2:1. Caffeine follows the same logic: the molecule is C8H10N4O2 while the empirical formula obtained from its percentages is C4H5N2O. Empirical formulas come from composition data; finding the molecular formula additionally needs the molar mass.
- How do I find the empirical formula from mass percent?
- Assume a 100 g sample so each percentage becomes grams, divide each mass by that element atomic weight to get moles, divide all the mole values by the smallest, then scale up to whole numbers. For 40.00% C, 6.71% H and 53.29% O the moles are 3.3303, 6.6567 and 3.3308 and the ratios are 1.0000 : 1.9989 : 1.0002, giving CH2O.
- What is the difference between empirical and molecular formula?
- The empirical formula is the lowest ratio; the molecular formula is the actual number of atoms per molecule and is a whole-number multiple of it. The empirical formula C4H5N2O becomes C8H10N4O2 once the molar mass of 194.19 g/mol is known. Multiplying the empirical formula mass by that integer is the standard route from one to the other.
- Why does the tool show decimals like C1.5?
- Because no multiplier between 1 and 10 made all the ratios land within 0.05 of a whole number, so the tool prints the raw ratios and flags them with a warning. That is not a formula: a fractional subscript signals that the percentages are imprecise, that the sample contains an undeclared component, or that the total does not sum to 100. Recheck the data and the sum before drawing conclusions. Note also that an empirical formula says nothing about the molar mass, so take the formula to the molecular formula tool when a molar mass is known: the empirical formula C4H5N2O becomes C8H10N4O2 once the molar mass of 194.19 g/mol is supplied.