How to Calculate Formal Charge and Hybridization, with a Free Calculator

Published: 19 Oct 2026 · Author: Scidart Academy · Reading time: ~7 min
Lewis structure of nitromethane with a positive formal charge on nitrogen and a negative formal charge on one oxygen
Nitromethane: the nitrogen carries a +1 formal charge and one oxygen carries −1.

Short answer: Formal charge is FC = V − N − B/2, where V is the valence electrons of the free atom, N the nonbonding electrons and B the bonding electrons. Hybridization comes from the steric number, the atoms bonded plus the lone pairs: 2 is sp, 3 is sp², 4 is sp³. In nitrate, N has FC = 5 − 0 − 8/2 = +1 and is sp². The free MolDraw formal charge and hybridization calculator does both for every atom of a molecule or ion.

What formal charge is

Formal charge is the charge an atom would have if every bond in a Lewis structure were shared equally between its two atoms. It is a bookkeeping tool. It tells you where the charge of an ion sits in a given Lewis structure and helps you pick the best structure when there are several.

The formula is FC = V − N − B/2.

  • V is the number of valence electrons of the free atom. For main-group elements it is the group number: C = 4, N = 5, O = 6, F and Cl = 7.
  • N is the number of nonbonding electrons on the atom. Each lone pair counts as 2.
  • B is the number of bonding electrons around the atom. A single bond counts as 2, a double bond as 4 and a triple bond as 6. B/2 is simply the number of bonds.

The formal charges of all atoms add up to the overall charge of the molecule or ion.

What hybridization is and how to find it

Hybridization describes which mix of s and p orbitals an atom uses for its σ bonds and lone pairs. Find it from the steric number: the number of atoms bonded to the atom plus its number of lone pairs. Double and triple bonds count once, because only one σ bond joins the two atoms.

Steric number 2sp, linear, 180°. Example: C in CO₂ and in HC≡CH.
Steric number 3sp², trigonal planar, 120°. Example: C in C=O, N in NO₃⁻.
Steric number 4sp³, tetrahedral, 109.5°. Example: CH₄, N in NH₃ (≈107°), O in H₂O (≈104.5°).
Steric number 5sp³d, trigonal bipyramidal. Example: PCl₅, SF₄, ClF₃.
Steric number 6sp³d², octahedral. Example: SF₆, XeF₄.

The conjugation exception. A nitrogen, oxygen or carbanion with a lone pair next to a π bond usually puts that lone pair in a p orbital, so it can delocalise. The atom then uses three hybrid orbitals and is sp², even though the simple count gives 4. This applies to the N of amides, aniline and pyrrole, the O of esters, phenol and furan, and the O⁻ of carboxylate and nitro groups.

How to use the calculator step by step

  1. Open the formal charge and hybridization calculator.
  2. Draw the structure in the editor, or type into the box SMILES or formula and press Calculate. Formulas such as NO3-, SO4^2- or XeF4 work for species with one central atom. For anything else, use SMILES such as C[N+](=O)[O-].
  3. Or press an example button: CO₂, NO₃⁻, Ozone, Nitromethane, Acetate, Aniline and more.
  4. Read the table. Each row shows V, N, B, the arithmetic Formal charge = V − N − B/2, the steric number, hybridization, electron geometry, shape and approximate bond angle. Tick Show hydrogen atoms in the table to list H atoms too.
  5. An asterisk on the steric number marks a conjugated lone pair (sp² instead of sp³).
  6. Use Manual formal charge check for a single atom in a structure you drew on paper: enter the element, atoms attached, bonds drawn and lone pairs.
  7. Press Open in MolDraw to keep the structure and export it.

Worked examples

1. Nitrate ion, NO₃⁻

One N=O double bond and two N–O single bonds. N has no lone pairs: FC = 5 − 0 − 8/2 = +1. Double-bonded O has 2 lone pairs: FC = 6 − 4 − 4/2 = 0. Each single-bonded O has 3 lone pairs: FC = 6 − 6 − 2/2 = −1. Sum = +1 + 0 − 1 − 1 = −1. N has three σ bonds and no lone pair, so it is sp² and trigonal planar (120°).

2. Ozone, O₃

Central O has one lone pair, one double and one single bond: FC = 6 − 2 − 6/2 = +1. The single-bonded end O has 3 lone pairs: FC = 6 − 6 − 1 = −1. The double-bonded end O is 0. The central O has steric number 3 (2 atoms + 1 lone pair), so it is sp² and bent, with a measured angle of 116.8°.

3. Cyanide ion, CN⁻

C≡N with one lone pair on each atom. C: FC = 4 − 2 − 6/2 = −1. N: FC = 5 − 2 − 6/2 = 0. The negative charge sits on carbon, which is why cyanide bonds to metals through C. Both atoms are sp.

4. Nitromethane, CH₃NO₂

N has four bonds (one C–N, one N=O, one N–O) and no lone pairs: FC = 5 − 0 − 8/2 = +1. The single-bonded O is −1. Drawing two N=O bonds would put 10 electrons on nitrogen, which a second-period atom cannot hold. N is sp², and the CH₃ carbon is sp³.

5. Acetamide, CH₃CONH₂

All formal charges are 0. The N has three σ bonds and one lone pair, so the simple count says sp³. The lone pair is next to the C=O π bond and delocalises, so the amide N is sp² and planar. This is why the C–N bond in amides has partial double-bond character.

Summary table

SpeciesAtom: formal charge, hybridization
CO₂C: 0, sp. O: 0, sp².
NO₃⁻N: +1, sp². Single-bonded O: −1 each.
CO₃²⁻C: 0, sp². Two single-bonded O: −1 each.
NH₄⁺N: +1, sp³, tetrahedral.
H₃O⁺O: +1, sp³, trigonal pyramidal.
CN⁻C: −1, sp. N: 0, sp.
SO₄²⁻ (two S=O)S: 0, sp³. Two O: −1 each.
CH₃COO⁻O⁻: −1, sp² (conjugated). Carboxyl C: sp².

Common mistakes

  • Subtracting B instead of B/2. With B counted as electrons, divide by 2.
  • Counting lone pairs instead of lone-pair electrons for N. Two lone pairs give N = 4.
  • Counting a double bond as two domains when finding the steric number.
  • Giving C, N or O more than 8 electrons. Only atoms of period 3 and below (P, S, Cl, Xe) can expand their octet.
  • Calling amide or aniline nitrogen sp³.
  • Confusing formal charge with oxidation number. In CO₂, C has formal charge 0 but oxidation number +4.

Exam tips (JEE, NEET, AP, A-level)

  • Check the sum. The formal charges must add up to the ion charge. If they do not, a lone pair is missing or extra.
  • Best Lewis structure: formal charges closest to zero, negative charge on the more electronegative atom, no octet above 8 for period-2 atoms.
  • JEE and NEET often ask for the hybridization of the central atom in ions such as I₃⁻ (sp³d), XeF₄ (sp³d²) and SO₄²⁻ (sp³). Use the steric number.
  • AP Chemistry free-response questions ask you to justify the best resonance or Lewis structure with formal charges. Write the V − N − B/2 arithmetic.
  • A-level organic questions on amide planarity or aniline basicity rely on the sp² nitrogen and its delocalised lone pair.

Questions and answers

What is the formula for formal charge?

Formal charge = V − N − B/2. V is the number of valence electrons of the free atom, N is the number of nonbonding electrons on the atom and B is the number of electrons in its bonds. A lone pair counts as 2 in N; a single bond counts as 2 in B.

What is the formal charge of N in NH4+?

Nitrogen has 5 valence electrons, no lone pairs and 4 single bonds (8 bonding electrons). FC = 5 − 0 − 8/2 = +1. Each hydrogen has FC = 1 − 0 − 2/2 = 0, so the ion has a charge of +1.

How do I find hybridization quickly?

Add the number of atoms bonded to the atom and its lone pairs. This is the steric number: 2 = sp, 3 = sp², 4 = sp³, 5 = sp³d, 6 = sp³d². A double or triple bond counts as one.

Why is the nitrogen in aniline sp2?

Its lone pair is next to the benzene ring and delocalises into the π system. A delocalised lone pair sits in a p orbital, so the nitrogen uses only three hybrid orbitals and is sp². Amide, pyrrole and enamine nitrogens behave the same way.

Can formal charge be +2 or −2?

Yes, but it is rare in a good Lewis structure. In the octet form of sulfate, with four S–O single bonds, sulfur has FC = 6 − 0 − 8/2 = +2. Structures with charges closer to zero are usually preferred.

Is formal charge a real charge?

No. It is bookkeeping that assumes every bond is shared equally. Real partial charges depend on electronegativity. In H3O+ the formal +1 sits on O, but the H atoms carry most of the real positive charge.

What is the hybridization of the carbon in CO2?

The carbon is bonded to two oxygen atoms and has no lone pairs, so its steric number is 2 and it is sp hybridized. The molecule is linear with a 180° O=C=O angle.

Last updated: