Precipitation forms when condensation inside clouds occurs at the level that the droplets become heavy enough to fall down to the Earth's surface. Rain, hail, freezing rain, snow and sleet are all types of precipitation that result from different conditions in the atmosphere.
Rain develops from cloud droplets or ice crystals; if it starts as crystals, the rain first takes the form of snowflakes, but they melt when they enter warmer layers of air, changing into raindrops. In thunderstorms that have a central updraft capable of hosting both rain and snow, snowflakes fall, but the liquid water freezes together with them, making ice pellets that keep growing as they add more water droplets. The updraft then tosses many of the pellets back up, if it is strong enough, and then the pellets fall through again, adding more ice. The stronger the storm, the more times each pellet goes through the cycle, and the larger the hail stone grows.
When frozen raindrops make it all the way to the ground, the precipitation is known as sleet. Freezing rain is slightly different; it hits the ground as a liquid but almost immediately freezes when in contact with the ground or other cold surfaces. As surface temperatures keep going down, freezing rain and sleet become snow, which consists of those ice crystals falling all the way to the ground.