'The genealogy of Hari', IAST: Harivaṃśa[1]) is an important work of Sanskrit literature, containing 16,374 shlokas, mostly in the anustubh metre.
This text is believed to be a khila (appendix or supplement) to the Mahabharata[2][3] and is traditionally ascribed to Vyasa.
The most celebrated commentary of the Mahabharata by Neelakantha Chaturdhara, the Bharata Bhava Deepa also covers the Harivamsa.
[4] The Adi Parva of Harivamsa describes the creation of the cosmos and the legendary history of the kings of the Solar and Lunar dynasties leading up to the birth of Krishna.
[5] Bhavishya Parva, the third book, includes two alternate creation theories, hymns to Shiva and Vishnu and provides a description of the Kali Yuga.
[9] Probably there was an oral previous version because later in time, the text was enlarged by additions and was matched in style to the Mahabharata.
When we compare the biography of Krishna, the account of Raji, and some other episodes as depicted in the Harivaṃśa, it appears to be anterior to the former.