Abu Umama Bahili reported,

Two men were mentioned to the Messenger of Allah ﷺ, one a devoted worshipper and the other a scholar. The Messenger of Allah ﷺ said, "The superiority of the scholar over the worshipper is like my superiority over the least of you."Then the Messenger of Allah ﷺ said, "Indeed, Allah, His angels, the inhabitants of the heavens and the earth, even the ant in its hole, and even the fish, all send blessings upon the one who teaches people what is good."

Tirmidhi 2685

Hasan

حدثنا محمد بن عبد الأعلى الصنعاني حدثنا سلمة بن رجاء حدثنا الوليد بن جميل حدثنا القاسم أبو عبد الرحمن

عن أبي أمامة الباهلي قال

ذكر لرسول الله ﷺ رجلان أحدهما عابد والآخر عالم فقال رسول الله ﷺ فضل العالم على العابد كفضلي على أدناكم ثم قال رسول الله ﷺ إن الله وملائكته وأهل السموات والأرضين حتى النملة في جحرها وحتى الحوت ليصلون على معلم الناس الخير

الترمذي 2685حسن
Contents
Reference
Commentary
Ayat
Collection
Jami Tirmidhi
Book
Knowledge
Chapter
Virtue of fiqh over worship
Numbering
Darussalam 2685
Tirmidhi 2685