Umar bin Khattab reported,

People used to be judged by revelation during the time of the Messenger of Allah ﷺ, but revelation has now ceased. We will only judge you now by what is apparent to us of your deeds. Whoever shows us good, we will trust him and bring him close, and we have nothing to do with his inner state. Allah will hold him accountable for his inner state. Whoever shows us evil, we will not trust him nor believe him, even if he claims that his inner state is good.

Bukhari 2641

Sahih

حدثنا الحكم بن نافع أخبرنا شعيب عن الزهري قال حدثني حميد بن عبد الرحمن بن عوف أن عبد الله بن عتبة قال سمعت

عمر بن الخطاب رضي الله عنه يقول

إن أناسا كانوا يؤخذون بالوحي في عهد رسول الله ﷺ وإن الوحي قد انقطع وإنما نأخذكم الآن بما ظهر لنا من أعمالكم فمن أظهر لنا خيرا أمناه وقربناه وليس إلينا من سريرته شيء الله يحاسبه في سريرته ومن أظهر لنا سوءا لم نأمنه ولم نصدقه وإن قال إن سريرته حسنة

البخاري 2641صحيح
Contents
Reference
Commentary
Ayat
Collection
Sahih Bukhari
Book
Testimonies
Chapter
Upright witnesses
Numbering
Darussalam 2641
Bukhari 2641