Not all solders are created equal - each solder is suited to a range of temperatures and applications. Choosing the right solder is important to get a good electrical connection that will last the life of the circuit and not be a point of failure.
Types of Solder
Electronics solder generally falls in to one of three types, a lead alloy solder, a lead-free solder or a silver alloy solder. Lead based solder is solder that is made from an alloy of tin and lead, sometimes with other metals as well. The reason that lead is combined with tin is that the resulting alloy has a lower melting temperature, an important property of solder when most electronic components are very heat sensitive! Lead alloy solder is often referenced by its alloy ratio such as 60/40 or 63/37, with the first number being the tin by weight and the second number being the amount of lead by weight. Both of these common alloys are good for common electronics, but 63/37 is an eutectic alloy, which means that it has a sharp transition between liquid and solid states as temperature changes. This property helps reduce cold solder joints that can happen when a part moves as the solder is cooling.
Lead alloy solder has been the standard solder used in electronics for decades, but the health issues associated with lead to move away from lead based solders. Europe lead the way in reducing lead by passing the Reduction of Hazardous Substances (RoHS) and Waste Electrical and Electronic Equipment (WEEE) which limited the amount of lead in any component to 0.1%. One of the most popular lead-free alloy is a 96.5/3/0.5 alloy with 96.5% tin, 3% silver, and 0.5% copper. Unfortunately most lead free alloys are more expensive than lead alloy solders, melt at a higher temperature and thus need a higher temperature flux, and provide stronger, but more brittle solder joints. The long term use of lead-free solder alloys are still being studied, although certain effects such as tin whiskers and soldering iron wear have already been identified as impacting the long term quality of lead-free electronics.
Silver alloy solder can be either lead-free or combined with lead. Silver was originally added to lead alloy solder to prevent an effect known as silver migration when silver plated components where soldered. With typical lead alloy solder, the silver in a silver plating will leach out in to the solder and cause the solder joint to become brittle and prone to breaking. Lead alloy solder with silver, such as 62/36/2 solder with 2% silver, 62% tin, and 36% lead, limits the silver migration effect and has better overall properties than lead alloy solder, but not enough better to justify the increase in cost.
Selecting the Right Solder
A number of different features can make selecting the right solder challenging. The right solder needs to take in to account the material being soldered, the use of flux, the size of the parts being soldered, and the potential health and safety issues of soldering.
Solder is available with none, one or several rosin (flux) cores running through the center of the solder wire. This embedded rosin flux helps the solder flow and bond to the parts being soldered, however, sometimes the rosin flux that is embedded in the solder is undesirable for a number of reasons, such as the cleaning method that must be used following the soldering or the presence of a strong acid flux (such as acid-flux solder used in plumbing which should never be used on electronics) and a separate flux is desireable.
Solder is also available in a number of diameters, with 0.02", 0.063" and 0.04" being common solder diameters. Larger diameter solders are great for large solder jobs, tinning larger guage or multistranded wires but make fine work such as surface mount soldering much more difficult. This is where the 0.02" and 0.04" solder becomes quite useful. Overall, most work can be done with just the 0.04" diameter solder, especially when combined with a little experience and adequate flux.