Sunan Ibn Majah, Book 37, Hadith 4340 (In-Book)

It was narrated from Abu Hurairah that the Messenger of Allah said: “If a person prays in public and does it well, and he prays in secret and does it well, then Allah says: ‘This man is truly My slave.’”

حَدَّثَنَا كَثِيرُ بْنُ عُبَيْدٍ الْحِمْصِيُّ، حَدَّثَنَا بَقِيَّةُ، عَنْ وَرْقَاءَ بْنِ عُمَرَ، حَدَّثَنَا عَبْدُ اللَّهِ بْنُ ذَكْوَانَ أَبُو الزِّنَادِ، عَنِ الأَعْرَجِ، عَنْ أَبِي هُرَيْرَةَ، قَالَ قَالَ رَسُولُ اللَّهِ ـ صلى الله عليه وسلم ـ ‏ "‏ إِنَّ الْعَبْدَ إِذَا صَلَّى فِي الْعَلاَنِيَةِ فَأَحْسَنَ وَصَلَّى فِي السِّرِّ فَأَحْسَنَ - قَالَ اللَّهُ عَزَّ وَجَلَّ هَذَا عَبْدِي حَقًّا ‏" ‏ ‏.‏

sunnah.com