There is no documented source that tells you exactly when, where and how tea was discovered. The first historical record that mentions tea dates back 2000 years, but according to one of the legends people were already drinking tea 5000 years ago.
The Chinese mythology says that tea was first discovered by the Chinese emperor and herbalist Shen Nung 2737 B.C. The emperor ordered his servants to always boil his drinking water to purify it (he was the one who decided that the Chinese should boil their water in order to raise the level of hygiene). Some leaves were blown by the wind into the water pot and turned the water into an amber color. Intrigued by this change of color he tried the infusion as an experiment. It tasted refreshing and the custom of drinking tea was spread since.