Jami` at-Tirmidhi 1081
Grading supplied with this record: Sahih (Darussalam)
Narration text is preserved in its supplied Arabic and English. Translated interfaces and reading guides do not add narration translations in other languages.
يَا مَعْشَرَ الشَّبَابِ عَلَيْكُمْ بِالْبَاءَةِ فَإِنَّهُ أَغَضُّ لِلْبَصَرِ وَأَحْصَنُ لِلْفَرْجِ فَمَنْ لَمْ يَسْتَطِعْ مِنْكُمُ الْبَاءَةَ فَعَلَيْهِ بِالصَّوْمِ فَإِنَّ الصَّوْمَ لَهُ وِجَاءٌ "
Abdullah bin Mas'ud narrated:
"We went with Allah's Messenger, while we were young men who had nothing. He said: 'O young men! You should marry, for indeed it helps in lowering the gaze and protecting the private parts. Whoever among you is not able to marry, then let him fast, for indeed fasting will diminish his sexual desire."
Full reference and source
Jami` at-Tirmidhi 1081 In-book : Book 11, Hadith 2 English translation : Vol. 2, Book 6, Hadith 1081
View source on Sunnah.com (opens in a new tab)