Kamsa was formerly the demon Kalanemi.
Kalnemi was a powerful demon who fought the devas during the Tarakamaya war. The Devas were defeated and they sought refuge with Lord Vishnu. Purushottama slew Kalanemi in battle and freed the devas from fear.
O Vishnu! In the tarakamaya battle, you killed the great daitya Kalanemi. He has been born as Ugrasena’s son. His name is Kamsa and the large-eyed one is the extender of the Bhoja lineage.
- 44, Harivamsa, Mahabharata.
At this very moment, Daityas led by Kalanemi have overrun the world of men and continually oppress the populace. The great asura Kalanemi, slain by mighty Visnu, has been reborn as Kamsa, son of Ugrasena.
- Chapter 1, book 5, Vishnu Purana.
Realising himself to be the great asura Kalanemi whom Visnu had formerly killed, born here again, he commenced hostilities with Yadavas. Being endowed with enormous power, he arrested his father Ugrasena, the king of Yadavas, Bhojas and Andhakas and took over the government of the Shurasena region.
- Chapter 1, 10th Skandha, Srimad Bhagavatam.