(21) باب أَجْرِ الْحَاكِمِ إِذَا اجْتَهَدَ فَأَصَابَ أَوْ أَخْطَأَ
Narrated `Amr bin Al-`As:
That he heard Allah's Messenger (ﷺ) saying, "If a judge gives a verdict according to the best of his knowledge and his verdict is correct (i.e. agrees with Allah and His Apostle's verdict) he will receive a double reward, and if he gives a verdict according to the best of his knowledge and his verdict is wrong, (i.e. against that of Allah and His Apostle) even then he will get a reward ."
Reference: Sahih al-Bukhari 7352
In-book reference: Book 96, Hadith 79
USC-MSA web (English) reference(deprecated numbering scheme): Vol. 9, Book 92, Hadith 450
Read hadith from the major collections in the app, with prayer times and a Qibla compass. Free.