Metal corrosion can be a big problem on a roof. And it’s generally easy to prevent. It can lead to leaks where there didn’t have to be leaks, repairs that shouldn’t have been necessary, money spent that shouldn’t have had to have been spent. One preventable factor in metal corrosion is galvanic corrosion, a process that results from dissimilar metals coming into contact in the presence of a conductive electrolyte. Because rainwater is a conductive electrolyte, on a roof you can count on the electrolyte often being present, so it’s important not to let the dissimilar metals come into contact. Don’t let your HVAC contractor install copper conduits on your aluminum roof. Don’t use galvanized steel nails with your copper flashings. The table below indicates which metals are generally compatible with one another; the closer they are in the table, the less you probably have to worry about corrosion. For a much, much, much more detailed explanation of galvanic corrosion, see MIL-STD-889C - Department of Defense - Standard Practice - Dissimilar Metals.

Anodic - Active - Most Susceptible to Corrosion
Magnesium and Magnesium Alloys
Zinc
Galvanized Steel
Galvalume
Aluminum
Lead
Tin
Steel
Cast Iron
Copper
Stainless Steel (300 Series, Active)
Stainless Steel (400 Series, Passive)
Brass
Bronze
Cupronickel
Monel
Nickel
Stainless Steel (300 Series, Passive)
Titanium
Cathodic - Noble - Most Resistant to Corrosion