Solar garden lights collect energy within a panel. Solar cells need direct sunlight to charge, so generally speaking, on long, sunny summer days, it's much easier to achieve a full charge than on cloudy days or during short winter days. The battery stores this energy.
Solar batteries are typically made from Nickel Cadmium (NiCd). The batteries are rechargeble (charged by the solar panels) and can generally last one to two years. Batteries should be replaced annually, since defective batteries can make your lights operate much less efficiently (or not at all).
Some solar lights use NiMH batteries instead. These batteries have different characteristics than the NiCd batteries and should not be used interchangeably. Always read the documentation that comes with your lights to see what type of batteries are needed.
NiCd batteries must be disposed of properly, due to harmful toxins contained within them. NiMH batteries, on the other hand, can be disposed of without harming the environment. NiMH batteries also tend to stand up better to the constant re-charging.
Solar garden lights have become much more effective in recent years, using efficient LED lamps with long lifespans. Solar lights should be placed where sunlight is most plentiful, without shade. Batteries that are fully charged can provide 10 to 12 hours of illumination during the night. The light will be strongest during the first few hours of operation, then gradually taper off as the energy in the battery is used up. Then, during the day when the sun re-appears, the batteries are re-charged. Good-quality solar lights can usually provide enough illumination from dusk until dawn if they are fully charged. Always use the right kind of batteries for your solar lights so that they operate at their best.