Count the total number of valence electrons for the atom
Count the number of nonbonding electrons assigned to the atom
Count half of the bonding electrons attached to the atom
Use the formula: Formal charge = Valence electrons – Nonbonding electrons – Half of bonding electrons
Assign the result as the atom’s formal charge
Repeat for each atom in the structure
Check that the sum of all formal charges equals the overall charge of the molecule or ion
