Valence electrons
Valence electrons are the electrons in an atom’s outermost energy level. They are the ones involved in bonding, so they decide most of an element’s chemistry.
To count them, find the highest energy level in the electron configuration and add up its electrons.
For main-group elements there is a shortcut: the valence count matches the last digit of the group number. Group 1 has 1, group 2 has 2, group 13 has 3, and so on up to group 18 with 8. Helium is the exception, with 2.
Atoms are especially stable with 8 valence electrons, like the noble gases. This is the octet rule. It is a useful guide, not a law: hydrogen is stable with 2, and some atoms hold more than 8.
A Lewis dot diagram shows the element symbol surrounded by one dot per valence electron.
Worked example: phosphorus
Configuration: 1s2 2s2 2p6 3s2 3p3
The highest level is 3. It holds 2 + 3 = 5 valence electrons. Phosphorus is in group 15, which agrees.
Common mistake
Counting only the last sublevel. Phosphorus ends in 3p3, but the 3s2 electrons are in the same outer level and count too.