Valence Electrons are the s and p electrons in the highest occupied ground state energy levels of an atom.
Why do we care?
The outermost electrons of an atom are where all the chemistry takes place. They explain the formation of ions and ionic compounds and are the ones involved in covalent bonding.
Example: Cl has the configuration 1s22s22p63s23p5.
Cl has 7 valence electrons. The valence electrons are 3s23p5.
Add an electron and you have the same configuration as Ar, but with one less positive charge: Cl-. This is a stable Noble Gas Configuration.
The Lewis symbol for Cl is
For Cl- we get . This forms an Octet, the 8 valence electrons of a Noble Gas.
Now check this out: Take away the Valence Electrons of Mg and what ion do you get? What Noble Gas does the magnesium ion configuration give you?
Metals are shiny and conduct heat and electricity. They can do this because they generate a "sea of electrons." Where do these electrons come from? Why don't the non-metals provide electrons like this? Check out the electronic configurations.