As per Hindu legend, during the original creation, cows were without horns and all the other predators were troubling them. They prayed to Shiva to provide them horns.
Shiva was pleased with the devotion and offered them horns. Since cows (called aa in Tamil) got horns at this place, it came to be known as Thiruamathur. The presiding image of lingam is sported holding the hooves of cow. As per another legend, the image of Ambal is sported with the tail of snake.
There is a small hole in the wall between the shrines of Shiva and Parvathi located in opposite shrines through which the deities see each other.
The original structure is believed to be existent from time immemorial, while the later additions are believed to have been built by Cholas, Pallavas, and the main temple was built by Atchudevaraya of Vijayanagar Dynasty.
There are inscriptions from later Chola emperors like Rajaraja Chola I (985–1014), Kulothunga Chola I (1070–1120),[3] and Rajendra Chola III (1246–1279).
Rajanarayana Sambuvaraya was a chieftain of Medieval Cholas whose contributions are documented in lithic inscriptions across various temples in modern-day Villupuram, Cuddalore, Tiruvannamalai and Kanchipuram districts and also in his Sanskrit work Madhuravijayam.
He repaired, revived the services and inaugurated festivals of the temple