وَعَنِ ابْنِ عَبَّاسٍ قَالَ: كُنْتُ خَلْفَ رَسُولِ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ يَوْمًا فَقَالَ: «يَا غُلَامُ احْفَظِ اللَّهَ يَحْفَظْكَ احْفَظِ اللَّهَ تَجِدْهُ تُجَاهَكَ وَإِذَا سَأَلْتَ فَاسْأَلِ اللَّهَ وَإِذَا اسْتَعَنْتَ فَاسْتَعِنْ بِاللَّهِ وَاعْلَمْ أَنَّ الْأُمَّةَ لَوِ اجْتَمَعَتْ عَلَى أَنْ يَنْفَعُوكَ بِشَيْءٍ لَمْ يَنْفَعُوكَ إِلَّا بِشَيْءٍ قَدْ كَتَبَهُ اللَّهُ لَكَ وَلَوِ اجْتَمَعُوا عَلَى أَنْ يَضُرُّوكَ بِشَيْءٍ لَمْ يَضُرُّوكَ إِلَّا بِشَيْءٍ قَدْ كَتَبَهُ اللَّهُ عَلَيْكَ رُفِعَتِ الأقلام وجفَّت الصُّحُف» رَوَاهُ أَحْمد وَالتِّرْمِذِيّ
Ibn Abbas (may Allah be pleased with him) narrates: One day I was (riding) behind the Messenger of Allah (peace and blessings be upon him), and he said: "Boy! Guard (the commands of) Allah, Allah will guard you. Take care of (the rights of) Allah, you will find Him before you. And when you ask, ask only from Allah; when you seek help, seek help only from Allah. And know that if the whole nation were to gather together to benefit you with something, they would not be able to benefit you except with what Allah has already written for you. And if they were to gather together to harm you, they would not be able to harm you except with what Allah has already written for you. The pens have been lifted and the pages have dried." Its chain is Hasan. Narrated by Ahmad and Tirmidhi.