Onigawara (鬼瓦) are decorative ridge-end tiles typically depicting a face of a Japanese Oni.
They are most often found on the roofs of Buddhist temples, although they can also occasionally be found at shrines, palaces, and residences.
They can be placed at the ends of the main ridge, "oomune" (大棟), or at the ends of decending ridges, "kudarimune" (降棟).
Onigawara are usually made of ceramic tile, but they can also be made from stone or wood.
— History
During the Nara and Heian periods, the decorative ceramic tiles were often designed as flowers and animals. During the Kamakura period, these tiles began to often depict an Oni design, bringing about the Onigawara we know today.
— Religion
Onigawara were believed to ward off evil.