Temples for all religious sects were built by people of all levels of society during the medieval period as a way of gaining religious merit and a worthy birth in the next world. The scale of the building depended on the resources of the donor. Elaborate poetic Sanskrit inscriptions recording the establishment of temples show that kings and queens built the largest monuments, though bankers and traders were also important patrons.
In medieval times it was believed that the individual soul kept its identity after death and became an autonomous religious entity, similar to but separate from, the gods. If one led a meritorious life – supporting worthy causes and defending society from wrong doers – then rebirth in heaven, in a deified form similar to the gods, was seen as guaranteed. Temple building was a crucial part of this process. Temples not only embodied and housed the gods which donors worshipped in this life, but represented their spiritual identity after death. This theology gave rise to a tradition of dynastic temples and temple complexes.

