Huayan Temple (Huayan si), lying in the southwestern part of Datong city, 1km west of the Nine Dragon Screen, got its name because it was, and remains, a major temple of the Huayan sect, a sub-category of the Buddhism popular in north China. It is one of the biggest temples in China.
The temple was originally built in the Liao Dynasty (916-1125 AD), as an ancestral temple to the imperial family, but it became an important Buddhist temple in the ensuing Jin Dynasty (1115-1234 AD). The temple's most prosperous years, apart from recent wealth, were during the Mongolian Yuan Dynasty (1271-1368 AD), when popularity allowed for the large scale repairs and renovation that give the temple its modern day look.
The Huayan Temple is divided into two parts, both with a separate entrance fee. The Upper Temple has various halls, the largest of which is the Grand Hall that houses five large Ming Dynasty (1368-1644 AD) Buddhas, 26 guardians and numerous attractive murals. Surrounding the Grand Hall are other halls for other Buddhas, including a side hall dedicated to Ksitigarbha, the guardian of the earth who is known in China as Dizang. The Lower Temple is smaller than the upper, but has a lot of charm. The main room here, the Bojiajiaocang Hall, contains some Liao Dynasty statues, and some heavenly deities, known in China as Tianwang.