Cavalry is one of the oldest military formation. Using horses increased mobility of units (comparing to infantry), increased speed of charging mounted soldiers and allowed them to attack infantry men from above, which was more successful.
The chariots, ie. wagons with soldiers, pulled by horses, are usually not considered as cavalry.
The discovery of saddle (late ancient period) allowed horsemen to became one of most important formations and service in cavalry was most prestigious, thus making chivalry and nobility in Europe. Some of the great armies like that of Genghis Khan consisted of horsemen only.
Cavalry was powerful because of its speed, usually not stoppable by infantry or artillery, and many great charges allowed spectacular victories (like Battle of Kircholm). However, some of them failed because of bad terrain (like Battle of Azincourt) or other reasons.
During time separate, more specialized cavalry formations were created, like:
In America, as there were no horses before Columbus, no cavalry units could have been used.
The end of cavalry forces begun during the ww1. Development of machine gun allowed to stop charges (of both infantry and cavalry). The trench warfare on the Western Front made cavalry useless. The reconnaissance, one of cavalry's main tasks, was taken by aeroplanes. Speed of advance was gained by tanks.
At the moment cavalries are used mostly as decorative formations. In some cases, the mounted police use horses to keep order, for example in fights against soccer-fans. In military, the infantry using helicopters is sometimes referred to "air cavalry", by remembering cavalry's golden age and making soldiers more prestigious.
The questions tagged with cavalry should cover history of this formation and its use. Counter-measures of cavalry (like pikes or halberds) are also welcome.