كتاب الجنائز
11  
The Book of Prayer - Funerals
(37)
Chapter: Leaving the funeral prayer for one who committed suicide
(37)
باب تَرْكِ الصَّلاَةِ عَلَى الْقَاتِلِ نَفْسَهُ ‏‏
Sahih Muslim 978

Jabir b. Samura reported:

(The dead body) of a person who had killed himself with a broad-headed arrow was brought before the Messenger of Allah (ﷺ), but he did not offer prayers for him.
حَدَّثَنَا عَوْنُ بْنُ سَلاَّمٍ الْكُوفِيُّ، أَخْبَرَنَا زُهَيْرٌ، عَنْ سِمَاكٍ، عَنْ جَابِرِ بْنِ سَمُرَةَ، قَالَ أُتِيَ النَّبِيُّ صلى الله عليه وسلم بِرَجُلٍ قَتَلَ نَفْسَهُ بِمَشَاقِصَ فَلَمْ يُصَلِّ عَلَيْهِ ‏.‏
Reference : Sahih Muslim 978
In-book reference : Book 11, Hadith 138
USC-MSA web (English) reference : Book 4, Hadith 2133
  (deprecated numbering scheme)