Srimad-Bhagavatam: Canto 9 - Chapter 1 - Verse 6


इत्युत्ससर्ज स्वं देहं निमिरध्यात्मकोविद: ।मित्रावरुणयोर्जज्ञे उर्वश्यां प्रपितामह: ॥ ६ ॥


ity utsasarja svaṁ dehaṁnimir adhyātma-kovidaḥmitrā-varuṇayor jajñeurvaśyāṁ prapitāmahaḥ


After saying this, Mahārāja Nimi, who was expert in the science of spiritual knowledge, gave up his body. Vasiṣṭha, the great-grandfather, gave up his body also, but through the semen discharged by Mitra and Varuṇa when they saw Urvaśī, he was born again.


Mitra and Varuṇa chanced to meet Urvaśī, the most beautiful prostitute of the heavenly kingdom, and they became lusty. Because they were great saints, they tried to control their lust, but they could not do so, and thus they discharged semen. This semen was kept carefully in a waterpot, and Vasiṣṭha was born from it.