Photo by nagualdesign
Portrait of Queen Catherine of Braganza
Photo by The Royal Collection
The most common legend is that Shen Nong (literally means "Divine Farmer"), also known as inventor of agriculture and Chinese medicine, discovered tea by accident in 2737 BC.  One day when he was enjoying his water that was just boil. (He believed boiled water is safer to drink and also increase longevity) Suddenly, the leaves of a tea plant fell into his cup. He tried it and liked the resulting beverage so much that tea was born. 
Tea drinking was likely to begin during the Shang Dynasty (1600 BC–1046 BC) in Yunnan, China for medicinal purposes. The first recorded drinking of tea was dated back to the 10th century BC China. The first tea monograph was written by a Chinese writer, Lu Yu, during the Tang dynasty around 760 CE. The book was called The Classic of Tea ("Chajing" in Chinese) and it introduces tea drinking in ten chapters. 
Tea was first introduced to Portuguese priests and merchants in China during the 16th century CE. Catherine of Braganza (a Portuguese princess), wife of King Charles II of England, took the tea habit to Great Britain around 1660, but tea was not widely consumed in Britain until the 18th century. In the beginning, tea was a luxury item only for special occasions, such as religious festivals, wakes, and domestic work gatherings such as quiltings.
In Britain and Ireland, tea had become an everyday beverage for all levels of society by the late 19th century when Indian tea began to arrive Europe in large quantities.