Built by the Pallava kings, the temple is dedicated to Lord Vishnu, known as Valavendai Gnanapiran. Also referred as the Sthalasayana Perumal Temple, the shrine was built to protect the splendid sculptures from the ocean waves. It is believed that when the temple got completed, the remaining structure was preserved to save it from the damage caused by sea. It has an Adivarsha shrine located near the seashore which is quite popular among the tourists. The temple is considered to be one of 108 holy abodes of Lord Vishnu and is visited by a huge number of tourists every year especially during the festival of Massi Makham.