800 years ago, Dharmasthala was known as Kuduma in Mallarmadi, a village in South Kanara. Here lived the Jain Chieftain Birmanna Pergade and his wife Ammu Ballalthi in a house called Nelyadi Beedu. Simple, pious and affectionate people, the Pergade family was known for its generosity and hospitality to all. According to the legend, the guardian angels of Dharma assumed human forms and arrived at Pergade's abode in search of a place where Dharma was being practised and could be continued and propagated. As was their habit, the Pergade couple hosted these illustrious visitors with great respect. Pleased by their sincerity and generosity, that night the Dharma Daivas appeared in the dreams of Shri Birmanna Pergade. They explained the purpose of their visit and instructed him to vacate his house for the worship of the Daivas and dedicate his life to the propagation of Dharma. Asking no questions, the Pergade built himself another house and began worshipping the Daivas at Nelyadi Beedu and same tradition continues even today.
Around 16th Century, Shri Devaraja Heggade invited Shri Vadiraja Swami of Udupi to visit the place. Pleased by Heggade's charity to all, the Swamiji named the place Dharmasthala, the abode of religion and charity. Thus the roots of charity and religious tolerance established by the Pergades 800 years ago have been nurtured and strengthened by twenty one generations of the Heggade family (Heggade being a derivative from Pergade). Today's Dharmasthala blossoms with the fruit of this selfless dedication.