The Messenger of Allah ﷺ said, "Choose carefully where you place your seed, marry those who are equal to you, and give your daughters in marriage to such men."
حدثنا عبد الله بن سعيد حدثنا الحارث بن عمران الجعفري عن هشام بن عروة عن أبيه
قال رسول الله ﷺ تخيروا لنطفكم وانكحوا الأكفاء وأنكحوا إليهم
No references are available.
Source, [its chain of transmission is very daif and rejected]. Daraqutni reported it (3/99) through Abdullah bin Saeed Ashaj, from Harith bin Imran, who is daif, Ibn Hibban accused him of fabricating hadith (Taqrib). He was corroborated by Ikrima bin Ibrahim, who is daif, his hadith is rejected, "he is worthless," "he is not trustworthy," see Lisan and other sources. Both of them were corroborated by daif narrators such as Abu Umaya bin Yaala and others. Some scholars mentioned another route from Tarikh Dimashq by Ibn Asakir, but I could not find its complete chain of transmission. Allah knows best.