Why Krishna, Balarama did not become King of Mathura or Dwaraka ?

Krishna, who was born to Kshatriya parents in Yadava clan, did not chose to coornate himself as King of Mathura, after killing Kansa.
Nor his elder brother Balarama chose to rule the kingdom. Their father Vasudeva also did not show any interest in getting crowned.
They did this to follow the rule imposed by their ancestor Yayati.
Krishna was not King of Yadavas

After killing Mathura King and his maternal uncle Kansa, Krishna and his father Vasudeva, corronated Krishna’s maternal grandfather Ugrasena as king of Mathura.
Their ancestor Yayati (ययाति) was a son of King Nahusha, who was ancestor of Pandavas. This Nahusha married Asoka Sundari, who was daughter of Lord Siva and Parvati.
The same Nahusha was cursed to live as python and was freed by Yudhishtira at Katasraj Mandir (now in Pakistan).
Yayati, once rescued Asura guru Sukracharya’s daughter Devayani, who fell into a well due to arrogance of Sharmishta.
This Sharmishta was daughter of Asura King Vrishaparva.
19th Chapter of Bhagavata Purana describes Yayati story in detail.
Yayati rescued her from a dry well. Yayati was instantly attracted to Devyani and pulled her up and professed his love for her.

Yayati said, “Unless your father gives you to me in marriage, I will not accept you as my wife.” Shukracharya gave in to his daughter’s request and agreed to give her away in marriage to King Yayati. As dowry, he gave away Sharmishtha as a maid to Devyani as a punishment for pushing her into the well.

Sharmishtha was given a place to live in a shaded glade called Ashok Vatika. One day Yayati happened to pass by Ashok Vatika where Sharmishtha lived. Seeing him, Sharmishtha confessed that she too was in love with the king and wanted him to marry her. She told him that she belonged to a royal family, and Yayati could marry her. Yayati agreed and they wed in secret. They continued to meet and hid the fact from Devayani that they were married.
Yayati had 2 sons with Sharmishta and 3 sons with Devayani.
One day Devayani discovered her husband’s secret marriage with Sharmishta and complains to her father Sukracharya, who curses Yayati to lose his virility, youth and instantly become an old man.
Devayani asks her father to withdraw this curse as her husband will suffer for lifetime. Sukracharya ammended his curse that if Yayati wanted, he could give his old age to someone, and take his youth from him. Yayati was relieved at the reprieve he was given, and was confident that his sons would willingly exchange their youth with him. Yayati requested all his five sons from Devyani and Sharmishtha one by one to give their youth to him to enjoy the worldly happiness. All the sons, except Puru (elder son of Sharmishta) rejected his demand. So, Yayati took the youth of Puru. Later on, Puru became the successor of King Yayati.
Devayani’s elder son Yadu was the first one to recieve his father’s request and he rejected it.

Yayati’s curse to his Descendants

Yayati cursed his 4 sons (except Puru) that none of them or their descendants will be successful kings.
Yayati cused Yadu to become cattle herder. He curses another son Druhya to live at a place, where the only mode of travel will be a boat.
He cursed another son to live in forests and rule only the tribal hunters.
Another son Anu was cursed that all his male descendants will die as soon as they attain youth.
Only Puru was allowed to become successor of Yayati.
This Puru‘s descendants were Pandavas and Kauravas.
King Puru went on to start his clan Puru Vamsa (dynasty), which later became Kuru Vamsa.

Rule imposed by Yayati was not respected by other descendants. Yadu’s elder son Sahasrajit had a grandson named Haihaya, who started Haihaya dynasty. One of his descendants was Kartavirya Arjuna, who was later killed by Parasurama. His sons were also killed in next battle and that dynasty ended.
Yadu’s second son Kroshta had a descendant named Vidarbha started a kingdom on his name. Today’s Vidarbha region in central India is the same kingdom. Krishna’s wife Rukmini belonged to Vidarbha.
Kroshtu’s other descendants (sons, daughter’s sons) formed Bhoja dynasty, Andhaka dynasty (Krishna belonged to his family), Vrishti dynasty (Satrajit and his daughter Satyabhama belong to this family), Chedi dynasty (Sisupala belonged to this kingdom).

Krishna’s paternal grandfather Surasena (शूरसेन, Śūrasena) also discarded his ancestor’s rule and took up the throne of Mathura.
One of Śūrasena’s daughter, Pritha, was adopted by childless Kuntibhoja (of Bhoja dynasty). Thus, she was called Kunti.
This is how she became paternal aunt of Krishna and Pandavas became his cousins.
After Śūrasena, his son Vasudeva got the oppurtunity to rule Mathura, but respecting his ancestor’s rule, he made Bhoja dynasty descendant Ugrasena as the king and remained his minister.
This Vasudeva married Rohini, but they had no children. One night sage Narada appeared his Rohini’s dream and revealed that, if her husband Vasudeva marries another lady, and after that lady has her first child, Rohini will also become pregnant.
Rohini tries to convince her husband for second marriage but fails. Knowing this, King Ugrasena offers the hand of his daughter Devaki to Vasudeva.
At the same time, Magadha king Jarasandha got both his daughters married to Ugrasena’s son Kansa, who was prince of Mathura.
After performing marriage of his sister Devaki with Vasudeva, Kansa was driving their chariot home and they all get to know that Devaki’s 8th child will kill Kansa.
Hearing this, Kansa throws the newly wed into jail. He has also thrown his father into jail for opposing him.
Vasudeva’s first wife Rohini took shelter at his friend Nanda’s house in Vrindavan. She delivered Balarama at Nanda’s house.

Krishna, at the age of 11 years and 6 months, killed Kansa on 14 December 3218 BCE (Siva Ratri), Krishna killed Kansa and started his Mathura Leela.
Krishna released his parents and his maternal grandparents Ugrasena and Padmavati from jail.
Following his father, Krishna and Balarama (who diverted Saraswati river) did not ascend the throne of Mathura (though it was once ruled by their paternal grandfather Śūrasena). Instead, they made maternal grandfather Ugrasena, back as king of Mathura.
Krishna, Balarama chose to remain in Mathura and later shifted kingdom to Dwaraka, but never intended to become kings.
7 out of 8 wives of Krishna were Kshatriya women (except Jambavati).
Though he was not official king, Krishna took active part in administration and also participated in many wars using weapons to kill many kings, who attacked Dwaraka.
So, Yadu dynasty were Chandra Vamsa kshatriyas and Krishna lived only for 11 years 6 months among cattle herders in Vrindavan.

If we observe Yadu dynasty’s history, most of them who ascended thrones, could not rule effectively for longer periods and perished midway.
Only Puru’s descendants ruled successfully for long period.
Vasudeva and his sons Balarama, Krisha respected Yayati’s words and remained away from throne.
However, Krishna’s grandson Anirudha became king of Mathura and was later succeeded by his son Vajranabha.
King Vajra was known as an invincible warrior and would remain among the few survivors of the Yadus’ battle (pradyumna died in this battle). King Vajra then had 16 idols of Krishna and other gods carved from a rare, imperishable stone called Braja and built temples to house these idols in and around Mathura so as to feel the presence of Lord Krishna.
This Vajranabha is said to have built the original Krishna temple in present Dwaraka (after Tsunami took over original Dwaraka), which was later rebuilt by many kings.