Abu Hurairah reported,

The Messenger of Allah ﷺ was asked, "Who is the noblest of people?"He replied, "The most God-fearing among them."They said, "That is not what we are asking you about."He said, "Then the noblest of people is Yusuf, the prophet of Allah, son of the prophet of Allah, son of the prophet of Allah, son of the friend of Allah."They said, "That is not what we are asking you about."He said, "Then are you asking me about the noble lineages of the Arabs? People are like ores. The best of them in the days of ignorance are the best of them in Islam, provided they gain understanding of the religion."

Azami 8407

Sahih

عن أبي هريرة

سئل رسول الله ﷺ من أكرم الناس؟ قال: أتقاه الله قالوا: ليس عن هذا نسألك قال: فأكرم الناس يوسف نبي الله ابن نبي الله ابن نبي الله ابن خليل الله. قالوا: ليس عن هذا نسألك قال: فعن معادن العرب تسألوني؟ الناس معادن، خيارهم الجاهلية، خيارهم في الإسلام إذا فقهوا.

الأعظمي 8407صحيح
Contents
Reference
Commentary
Ayat
Collection
Jami al-Kamil
Book
Stories of the prophets
Chapter
Ibrahim and his sons, peace be upon them
Section
Yusuf عليه السلام being a prophet, son of a prophet, son of a prophet, son of a prophet
Numbering
Jami al-Kamil 8407 (2nd edition)
Azami 8407