I heard the Messenger of Allah ﷺ say, "It is better for one of you to go out, gather firewood on his back, give some of it in charity, and use it to become independent of people, than to beg from a man who may give him or refuse him. The upper hand is better than the lower hand, and begin with those you support."
حدثنا هناد حدثنا أبو الأحوص عن بيان بن بشر عن قيس بن أبي حازم
سمعت رسول الله ﷺ يقول لأن يغدو أحدكم فيحتطب على ظهره فيتصدق منه فيستغني به عن الناس خير له من أن يسأل رجلا أعطاه أو منعه ذلك فإن اليد العليا أفضل من اليد السفلى وابدأ بمن تعول
Muslim also narrated it, Zakat, chapter on the dislike of asking people, no. 1042, from Hannad bin Sari, with the same wording.On this subject, there are also narrations from Hakeem bin Hizam [Bukhari, no. 1427, and Muslim, no. 1034], Abu Saeed Khudri [Bukhari, no. 1465, and Muslim, no. 1052], Zubayr bin Awwam [Bukhari, no. 1471], Atiya Saadi [Ahmad, 4/226, and Abd bin Humayd, no. 485], Abdullah bin Masud [previously mentioned, no. 650], Masud bin Amr [Abu Naeem in Marifat al-Sahaba, 5/2535, no. 6134], Ibn Abbas [I did not find it], Thawban [Abu Dawud, no. 1643, and Ibn Majah, no. 1837], Ziyad bin Harith Sudai [Abu Dawud, no. 1630, and Bayhaqi, 4/174], Anas [Abu Dawud, no. 1641], Habashi bin Junada [previously mentioned, nos. 653, 654], Qabisa bin Mukharaq [Muslim, no. 1044], Samura [coming up, no. 681], and Ibn Umar [Bukhari, no. 1429, and Muslim, no. 1033].