The Messenger of Allah ﷺ said, "There was a tree that used to harm people passing along the road. A man cut it down and removed it from the path, and for this he entered Paradise."
حدثنا عفان قال حدثنا حماد قال أخبرنا ثابت عن أبي رافع
أن رسول الله ﷺ قال كانت شجرة تؤذي أهل الطريق فقطعها رجل فنحاها فدخل الجنة
Its isnad is sahih. Bukhari narrated it, 2/139, no. 652, in Fath al-Bari, in Book of Adhan, chapter on the merit of hastening to Dhuhr. Muslim narrated it, 4/2021, no. 1914, in Book of Righteousness, chapter on the merit of removing harm. Abu Dawud narrated it, 4/362, no. 5245, in Book of Manners, chapter on removing harm. And Tirmidhi narrated it, 4/341, no. 1958, similar to Muslim. All of them with different wordings.