
The Lugos region, including the present-day Hegyhátszentmárton, was granted to Gregorius Magnus of the Gatal family in 1181. It was in his time or that of his son of the same name that the first church was built in the area, around which the village was later organised. Hegyhátszentmárton and the Lugos Valley belonged to the Ivánczy family in the 15th century. Between 1548 and 1562, Péter Ivánczy, the deputy governor, built a castle and a fortress on the northern edge of the village, on the high bank of the Rába. The castle was destroyed around 1580, but its remains are still visible today. The stones of the medieval church, which had fallen into ruins by the middle of the 17th century, were carried to Őriszentpéter by Bernát Csány in 1654. The present church, dedicated to St. Martin, was built in 1905.
.