كتاب الصيام
13  
The Book of Fasting
(34)
Chapter: The Prophet's Fasts at times other than Ramadan; and it is recommended to ensure that no month is free of fasting
(34)
بَاب صِيَامِ النَّبِيِّ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ فِي غَيْرِ رَمَضَانَ وَاسْتِحْبَابِ أَنْ لَا يُخْلِيَ شَهْرًا عَنْ صَوْمٍ
Sahih Muslim 1157 a

Ibn Abbas (Allah be pleased with both of them) reported:

The Messenger of Allah (ﷺ) did not fast throughout any month except during ramadan. And when he observed fast (he fasted so continuously) that one would say that he would not break (them) and when he Abandoned, he abandoned (so continuously) that one would say: By Allah, perhaps he would never fast.
حَدَّثَنَا أَبُو الرَّبِيعِ الزَّهْرَانِيُّ، حَدَّثَنَا أَبُو عَوَانَةَ، عَنْ أَبِي بِشْرٍ، عَنْ سَعِيدِ بْنِ جُبَيْرٍ، عَنِ ابْنِ عَبَّاسٍ، - رضى الله عنهما - قَالَ مَا صَامَ رَسُولُ اللَّهِ صلى الله عليه وسلم شَهْرًا كَامِلاً قَطُّ غَيْرَ رَمَضَانَ ‏.‏ وَكَانَ يَصُومُ إِذَا صَامَ حَتَّى يَقُولَ الْقَائِلُ لاَ وَاللَّهِ لاَ يُفْطِرُ ‏.‏ وَيُفْطِرُ إِذَا أَفْطَرَ حَتَّى يَقُولَ الْقَائِلُ لاَ وَاللَّهِ لاَ يَصُومُ ‏.‏
Reference : Sahih Muslim 1157a
In-book reference : Book 13, Hadith 230
USC-MSA web (English) reference : Book 6, Hadith 2583
  (deprecated numbering scheme)