Caution: Translations of Quran and Ḥadīth may lead to possible misapplications and misinterpretations. This site is intended for students of sacred knowledge that are proficient in comprehending classical Arabic and have a strong foundation in Islamic sciences. Also note that religious injunctions rely on several aspects beyond what one may glean through reading individual aḥādīth.
tirmidhi:2648Muḥammad b. Ḥumayd al-Rāzī > Muḥammad b. al-Muʿallá > Ziyād b. Khaythamah > Abū Dāwud > ʿAbdullāh b. Sakhbarah > Sakhbarah

narrated that the Prophet ﷺ said: "Whoever seeks knowledge, he is atoning for what has passed (of sins while doing so)."  

الترمذي:٢٦٤٨حَدَّثَنَا مُحَمَّدُ بْنُ حُمَيْدٍ الرَّازِيُّ حَدَّثَنَا مُحَمَّدُ بْنُ الْمُعَلَّى حَدَّثَنَا زِيَادُ بْنُ خَيْثَمَةَ عَنْ أَبِي دَاوُدَ عَنْ عَبْدِ اللَّهِ بْنِ سَخْبَرَةَ عَنْ سَخْبَرَةَ

عَنِ النَّبِيِّ ﷺ قَالَ مَنْ طَلَبَ الْعِلْمَ كَانَ كَفَّارَةً لِمَا مَضَى  

قَالَ أَبُو عِيسَى هَذَا حَدِيثٌ ضَعِيفُ الإِسْنَادِ أَبُو دَاوُدَ يُضَعَّفُ وَلاَ نَعْرِفُ لِعَبْدِ اللَّهِ بْنِ سَخْبَرَةَ كَبِيِرَ شَيْءٍ وَلاَ لأَبِيهِ وَاسْمُ أَبِي دَاوُدَ نُفَيْعٌ الأَعْمَى تَكَلَّمَ فِيهِ قَتَادَةُ وَغَيْرُ وَاحِدٍ مِنْ أَهْلِ الْعِلْمِ

See similar narrations below:

Collected by Dārimī, Suyūṭī
darimi:580Muḥammad b. Ḥumayd > Muḥammad b. al-Muʿallá > Ziyād b. Khaythamah > Abū Dāwud > ʿAbdullāh b. Sakhbarah > Sakhbarah

narrated that the Prophet ﷺ said: "Whoever seeks knowledge, he is atoning for what has passed (of sins while doing so)." (Using translation from Tirmidhī 2648)  

الدارمي:٥٨٠أَخْبَرَنَا مُحَمَّدُ بْنُ حُمَيْدٍ حَدَّثَنَا مُحَمَّدُ بْنُ الْمُعَلَّى حَدَّثَنَا زِيَادُ بْنُ خَيْثَمَةَ عَنْ أَبِي دَاوُدَ عَنْ عَبْدِ اللَّهِ بْنِ سَخْبَرَةَ عَنْ سَخْبَرَةَ

عَنِ النَّبِيِّ ﷺ قَالَ «مَنْ طَلَبَ الْعِلْمَ كَانَ كَفَّارَةً لِمَا مَضَى»