(46) باب أَهْلُ الْعِلْمِ وَالْفَضْلِ أَحَقُّ بِالإِمَامَةِ
Narrated Abu Musa:
"The Prophet (ﷺ) became sick and when his disease became aggravated, he said, "Tell Abu Bakr to lead the prayer." `Aisha said, "He is a softhearted man and would not be able to lead the prayer in your place." The Prophet (ﷺ) said again, "Tell Abu Bakr to lead the people in prayer." She repeated the same reply but he said, "Tell Abu Bakr to lead the people in prayer. You are the companions of Joseph." So the messenger went to Abu Bakr (with that order) and he led the people in prayer in the lifetime of the Prophet.
Reference: Sahih al-Bukhari 678
In-book reference: Book 10, Hadith 72
USC-MSA web (English) reference(deprecated numbering scheme): Vol. 1, Book 11, Hadith 646