A little more information:
The history of matcha in Japan is known to have commenced in the 12th Century when the Zen monk Eisai [栄西] (1141-1215) brought tea seeds that he had gathered on a study trip to China. However, in the 8-9th Century, Buddhist Monks Saichō [最澄] (767-822) and Kūkai [空海] (774-835) had already brought tea seeds from China. At that time tea was processed into compressed cubical bricks. It was in the following century that a powdered kind of tea, resembling what we nowadays perceive as the matcha used in matcha lattes and so on… This powdered form of tea became very familiar at Chinese Chan [jp: Zen] monasteries, and was revered for both its vitalizing and healing benefits. As well as implementing this application of tea in his own Buddhist praxis, Eisai also wrote a book titled ‘Kissa Yōjōki’ [喫茶養生記], which translates as ‘Drinking Tea for Health’ in which he explains the various health benefits that can be gained from consuming tea.
In 1191, it is believed that Eisai recommended the cultivation and regular consumption of tea to one of his pupils; Myōe [明恵] (1173–1232) who was a Buddhist Monk serving as the chief incumbent at Kōzan-ji [高山寺] on the Toganoō [栂ノ尾] mountain north-west from Kyoto. He took the advice of his master very seriously, and tended to the cultivation of tea bushes in his direct temple precincts. In due course, he discovered that the fertility of the soil, and the morning dew forming on the tea leaf as a result from the neighboring Kiyotaki river, were excellent conditions for the cultivation of tea. It is from this point forward that the consumption of tea, mainly in a powdered form, became more widely spread throughout the country, initially for use in Buddhist monasteries, and later also by the military elite.