Lightning is the passage of electric current from the clouds in the sky. The clouds accumulate electrostatic charge due to action of UV rays from the Sun or due to presence of miscellaneous impurities and ionic gases like (chlorine or florine or oxygen etc.). The charges induce opposite charges on the other ends of clouds or in neighboring clouds.
When the potential difference between the ends of clouds is very high due to high charges, then a large spark (electric discharge) passes between them from higher potential to lower potential. This is intra-cloud lightning/discharge.
Similarly, there is an inter-cloud discharge between two clouds. Further, there is a discharge between a cloud and Earth's surface, which is at potential zero.
Lightning generally occurs during a rain. This is because there is a lot of humidity in the clouds and the impure water drops facilitate passage of charges and increase the charge also.
The voltage in a cloud could be in terms of 1 to 100 million volts. The discharge current can be in thousands of amperes in a fraction (millisecond) of a second. The clouds are at a distance of 1 km to 4 km from the surface of Earth.
The heat generated in a lightning when it strikes a building or a tree is enormous due to high current. So they are instantaneously burnt into ashes.
The lightning is also called thunder bolt. Usually the sound energy in a lightning is heard after many seconds after a discharge. Some times multiple lightnings happen in the sky in a space of an hour too. After the charge on clouds decreases, the lightnings stop.
It is safe to install a lightning protector rods on roofs of buildings or houses. The top of this rod forms an equal and oppose charge due to electro-static induction, and as it is a metal, it conducts the charge in to the Earthing.
Usually, the lightning disturbs electromagnetic waves like FM radio or TV signals being transmitted at that time. Even the signals to satellites do get disturbed.