Grini said:The electric current flows from the higher charge to the lower charge (ground) in a (direct current) electric circuit (very basic explanation). Lightning begins with 2 "locations" with different charges. Suddenly the charges of both "locations" connect with each other, discharge and "grounding happens". This discharge you can see with lightning and hear with thunder. (Specialists in electrical engineering and similar sciences can have a good laugh about my explanation if they like. :D). Pierre explains this topics extensively in his book.
In general, the ground below the cloud is more positive than the cloud above because the electrons from the Earth's surface are pulled up by the positive ionosphere and captured by atmospheric dust. Notice also that the weak magnetic field exhibited by the Sun and the Earth increase the quantity of high energy cosmic rays which catalyses nucleation (stimulate the formation of water droplets in the atmosphere) hence the overall increase in rainfall and cloud cover.
Here is an excerpt of ECHCC explaining one aspect of cloud lightning formation and discharge:
ECHCC said:The two drawings above depict cloud formation followed by a cloud-to-ground lightning discharge. The 6 steps of the process listed below correspond to the figures in red.
Top drawing:
1) The proton-rich solar wind projects positively charged particles into the Earth’s ionosphere.
2) As the positive charge of the ionosphere increases, it begins to attract electrons located on Earth’s surface.
3) The electrons from Earth’s surface rise in the air and are captured by low-mobility atmospheric particles (dust, droplets).
4) Similarly, protons from the ionosphere are attracted by the Earth’s negative charge and start sinking into the atmosphere, eventually being captured by atmospheric particles.
Bottom drawing:
5) The upwards electron flow creates an electron-deficient region on Earth’s surface (region within the red line) and an electron-rich area at the bottom of the cloud.
6) When the electric potential difference is high enough, lightning strikes, carrying a massive electron flow back to the ground that re-balances electric charges between the bottom of the cloud mass and the locally positive region on Earth’s surface.