The economic importance of rusting is such that it has been estimated that the cost of corrosion is over 1% of the world's economy. (25% of the annual steel production in the USA goes towards replacement of material that has corroded.)
Rusting of iron consists of the formation of hydrated oxide, Fe(OH)3 or FeO(OH), and is an electrochemical process which requires the presence of water, oxygen and an electrolyte - in the absence of any one of these rusting does not occur to any significant extent. In air, a relative humidity of over 50% provides the necessary amount of water and at 80% corrosion is severe.
The process is complex and will depend in detail on the prevailing conditions, for example, in the presence of a small amount of O2
the anodic oxidation will be: Fe → Fe2+ + 2e-
and the cathodic reduction: 2H2O + 2e- → H2 + 2OH-
i.e. overall: Fe + 2H2O → H2 + Fe2+ + 2OH-
i.e Fe(OH)2 and this precipitates to form a coating that slows further corrosion.
If both water and air are present, then the corrosion can be severe with oxygen now as the oxidant
the anodic oxidations: 2Fe → 2Fe2+ + 4e-
and the cathodic reduction: O2 + 2H2O + 4e- → 4OH-
i.e. overall: 2Fe + O2 + 2H2O → 2Fe(OH)2 with limited O2, magnetite is formed (Fe3O4), otherwise the familiar red-brown
Fe2O3 H2O “rust” is found.
The presence of an electrolyte is required to provide a pathway for the current and, in urban areas, this is commonly iron(II) sulfate formed as a result of attack by atmospheric SO2 but, in seaside areas, airborne particles of salt are important.
The anodic oxidation of the iron is usually localized in surface pits and crevices which allow the formation of adherent rust over the remaining surface area.
Galvanised iron is the name given to iron that has been dipped into molten zinc (at about 450°C) to form a thin covering of zinc oxide. One level of rust prevention occurs through a purely mechanical method since it is more difficult for water and oxygen to reach the iron. Even if the layer becomes somewhat worn though another reason corrosion is inhibited is that the anodic processes are affected.
The E° for zinc oxidation (0.76V) is considerably more positive that E° for iron oxidation (0.44V) so the zinc metal is oxidized before the iron. Zn2+ is lost to the solution and the zinc coating is called a sacrificial anode.
Foodstuffs are often distributed in "tin cans" and it has generally been easier to coat the iron with a layer of tin than with zinc. Another benefit is that tin is less reactive then zinc so does not react as readily with the contents. However the electrode oxidation potential for Sn/Sn2+ is 0.14V so once again iron becomes the anode and rust will occur once the coating is worn or punctured.
Another technique is to treat the iron surface with dichromate solution.
2 Fe + 2 Na2CrO4 + 2 H2O -> Fe2O3 + Cr2O3 + 4 NaOH
The iron oxide coating formed has been found to be impervious to water and oxygen so no further corrosion can occur.