Picture the surface of a metal electrode in contact with an electrolyte at left. A voltage develops across the metal/solution interface because charges are distributed differently on either side of the interface.
Suppose some of the metal cations move from the metal side to the solution side. If the metal is zinc, we can write an equation to describe this process.
Zn(s) = Zn2+(aq) + 2e-
Two electrons are left behind in the metal; the charge on the metal strip becomes more negative. The solution becomes more positive. The voltage between the solution and metal will increase because the difference in charge will increase.
If the electrons are removed somehow, the process can continue, and you'll see the zinc strip gradually dissolve.
The reverse process also occurs. You can have metal cations move from the solution to the metal.This process could be described as
Zn2+(aq) + 2e- = Zn(s)
If more electrons are supplied, this process can continue, and most of the zinc ions in solution will end up deposited on the surface of the zinc strip.
Capture of metal cations by the metal will occur at the same time other metal cations are leaving; the voltage across the metal/solution boundary will depend on which of these two processes dominates.
The first process (conversion of metal atoms into metal cations in solution) often dominates for metals that give up electrons easily.
Lots of things affect how easily a metal will give up its electrons. For example, metal atoms at the bottom of a column on the periodic table tend to give up electrons more easily than atoms at the top of the column. The outer electrons are farther from the nucleus. The inner electrons tend to wrap around the nucleus and hide its full positive charge from the outer electrons, too. Because the attraction between the nucleus and the outer electrons is weakened, the electrons are more easily lost. That's why potassium is more reactive than sodium.
To predict the standard electrode voltages, you have to consider more than just energetics (how much energy does it take to pry an electron out of the metal? How much energy is released when an extra electron is added to the metal?) Entropy effects play an important role as well- but that's another question.
Many other factors affect electrode potentials. If you change the concentration of electrolytes in the solution, or the concentration of metal cations in the solution, you change the charge difference across the boundary. Ion concentrations in the solution have a strong effect on the voltages across the metal/solution boundary.
Author: Fred Senese firstname.lastname@example.org