Image taken from: http://www.mthurricane.com/
Rain clouds become charged through a complicated and largely unknown process. There are two major categories of hypotheses that describe the process: those that include ice as a key factor and those that do not. The ice hypothesis holds that the charges are a result of the separation of ice and water droplets within the cloud, as experiments have shown that freezing a dilute solution of water causes the ice to gain a negative charge and the water to keep a positive charge. Inside a cloud, rising air pulls small droplets of water up and away from the larger falling ice particles, causing the upper half of the cloud to gain a positive charge and the lower half to gain a negative charge. Other experiments have shown that small, slowly falling drops of water become positively charged while larger, quickly falling drops of water become negatively charged, thus causing the upper half of the cloud to gain a positive charge while the lower half gains a negative charge. It is most widely believed that ice is a contributing factor in the charging process, as lightning is not generally seen until ice has formed in the upper layers of thunderclouds.