Princely state of Cochin was initially a Hindu Kingdom on the Malabar Coast in South India. Once a vast kingdom having power over Ponnani and Thottapally, the kingdom diminished to its minimal area due to the incursions by the Zamorin of Calicut. During the British-Raj, Cochin stood at the head of all districts and states in Southern India except Madras City. It was the chief port of Malabar and the third in importance in Madras Presidency. It is today a part of Kerala state of the Indian Union.
Internal conflict for the throne led to the making of five Thavazhi or royal families. They were – Mootha Thavazhi, Elaya Thavazhi, Mrungoor Thavazhi, Palluruthi Thavazhi and Chaziyoor Thavazhi. The eldest member of all the five thavazis was crowned the king. But after a few years this rule was altered. After discussions with the nobles and Brahmins it was decided that the king was to be selected from the five tahvazis only after checking his horoscope, strength and intelligence. The eldest member was called Perumpadapu Moopil who had the authority of decision-making regarding temples in the kingdom.
Portuguese commander Kabral had made a note of this system in AD 1500 it states that "The Kings of Cochin during their old age used to live in the temples like sanyasins. Thus when one king retires to appoint another king, Zamoorins had to be consulted. The chosen king when retires has to acknowledge the position of Perumpadapu Moopil. But in 1510 King Unnirama Koyil II preferred not to retire on the advice of the Portuguese and remained on the thone. After this incidence the new custom of election was stopped and the old custom is followed till date. Only the eldest member from the Elaya Thavazhi was allowed to be crowned the king.
There is no proper record on the list of rulers of Cochin before the arrival of the Portuguese. But some names are written on grandhas and documents which are the only record. Veerakerala Varma nephew of Cheraman Perumal is supposed to be the first king of Cochin. But the only records are found only from 1503 AD.