DevTools Logo

Chemical Equation Balancer

Chemical Equation Balancer

Balance reactions with exact integer coefficients — plus element totals and the matrix method.

Runs in your browser

Reaction

16 chars

Separate species with + and sides with ->. Hydrates use· or * (CuSO4·5H2O); charges use ^ (Fe^3+). The page address updates so you can share the exact equation. Press ⌘/Ctrl+Enter to balance.

Try a reaction

Balanced equation

3 coefficients
4 Fe + 3 O2 -> 2 Fe2O3

Element check

Element totals on each side of the equation
ElementReactantsProductsCheck
Fe44
O66
How it was solved (matrix method)

Each row is an element (plus charge when present). Reactants are positive, products negative. Gauss-Jordan elimination took 1 row operations and left a nullspace of dimension 1.

Element matrix, one column per species
ElementFeO2Fe2O3
Fe10-2
O02-3
Reduced row echelon form of the element matrix
RREFx1x2x3
Fe10-2
O01-3/2

Nullspace basis: (4, 3, 2)
Coefficients: (4, 3, 2)

Balancing confirms atom conservation, not that a reaction is feasible or safe.

Examples

Synthesis

Fe + O2 -> Fe2O3 balances to 4 Fe + 3 O2 -> 2 Fe2O3.

Combustion

C3H8 + O2 -> CO2 + H2O balances to 1, 5, 3, 4.

Redox

KMnO4 + HCl -> KCl + MnCl2 + H2O + Cl2 yields 2, 16, 2, 2, 8, 5.

Hydrate

CuSO4·5H2O -> CuSO4 + 5 H2O — the dot introduces water of crystallisation.

About this tool

Type a reaction such as KMnO4 + HCl -> KCl + MnCl2 + H2O + Cl2. The balancer parses formulas with parentheses, square brackets and hydrates, builds an element matrix, solves it with exact rational Gauss-Jordan elimination and scales the nullspace vector to the smallest whole-number coefficients. It then shows totals for every element and the worked matrix. Charge notation such as Fe^3+ is supported and included in the conservation check. Balancing proves atom conservation only — it does not assess reaction feasibility or safety.

Everything runs locally in your browser — your inputs stay on your device and are never uploaded to a server.

What this tool does not do

  • Processes only the inputs provided in this session without connecting to external accounts or background servers.
  • Runs entirely in the current browser tab; nothing is synced across devices or backed up to a server.

How to use this tool

  1. Type an unbalanced reaction

    Enter reactants and products using -> or = (for example Fe + O2 -> Fe2O3).

  2. Inspect integer coefficients

    Read the balanced stoichiometric equation and atom-conservation verification table.

  3. Review matrix steps

    Expand the worked linear-algebra solution or copy the formatted equation.

Use cases

Synthesis

Fe + O2 -> Fe2O3 balances to 4 Fe + 3 O2 -> 2 Fe2O3.

Combustion

C3H8 + O2 -> CO2 + H2O balances to 1, 5, 3, 4.

Redox

KMnO4 + HCl -> KCl + MnCl2 + H2O + Cl2 yields 2, 16, 2, 2, 8, 5.

Hydrate

CuSO4·5H2O -> CuSO4 + 5 H2O — the dot introduces water of crystallisation.

Common mistakes

Mistake:Can it parse parentheses, brackets, and hydrate dots?

Fix:Yes. Formulas like Ca(OH)2, [Fe(CN)6], and CuSO4*5H2O expand group multipliers accurately before building the element matrix.

Mistake:What happens if an equation is chemically impossible to balance?

Fix:If an element appears on only one side or the conservation matrix has no all-positive solution, the tool explains the exact missing element or rank conflict instead of guessing.

Frequently asked questions

How does algebraic matrix balancing work?

Each element forms a conservation row across reactants and products; Gaussian elimination over exact rational arithmetic finds the nullspace basis and scales it to the smallest positive integer stoichiometric coefficients.

Can it parse parentheses, brackets, and hydrate dots?

Yes. Formulas like Ca(OH)2, [Fe(CN)6], and CuSO4*5H2O expand group multipliers accurately before building the element matrix.

What happens if an equation is chemically impossible to balance?

If an element appears on only one side or the conservation matrix has no all-positive solution, the tool explains the exact missing element or rank conflict instead of guessing.

Does balancing guarantee a reaction occurs in real life?

No. Stoichiometric balance only enforces atom conservation; thermodynamic feasibility and reaction kinetics depend on experimental chemistry.