Language:
كتاب التعبير
91  
Interpretation of Dreams
(46)
Chapter: A bad dream should not be told to anybody
(46)
باب إِذَا رَأَى مَا يَكْرَهُ فَلاَ يُخْبِرْ بِهَا وَلاَ يَذْكُرْهَا
Sahih al-Bukhari 7044

Narrated Abu Salama:

I used to see a dream which would make me sick till I heard Abu Qatada saying, "I too, used to see a dream which would make me sick till I heard the Prophet (ﷺ) saying, "A good dream is from Allah, so if anyone of you saw a dream which he liked, he should not tell it to anybody except to the one whom he loves, and if he saw a dream which he disliked, then he should seek refuge with Allah from its evil and from the evil of Satan, and spit three times (on his left) and should not tell it to anybody, for it will not harm him. "

حَدَّثَنَا سَعِيدُ بْنُ الرَّبِيعِ، حَدَّثَنَا شُعْبَةُ، عَنْ عَبْدِ رَبِّهِ بْنِ سَعِيدٍ، قَالَ سَمِعْتُ أَبَا سَلَمَةَ، يَقُولُ لَقَدْ كُنْتُ أَرَى الرُّؤْيَا فَتُمْرِضُنِي حَتَّى سَمِعْتُ أَبَا قَتَادَةَ يَقُولُ وَأَنَا كُنْتُ لأَرَى الرُّؤْيَا تُمْرِضُنِي، حَتَّى سَمِعْتُ النَّبِيَّ صلى الله عليه وسلم يَقُولُ ‏ "‏ الرُّؤْيَا الْحَسَنَةُ مِنَ اللَّهِ، فَإِذَا رَأَى أَحَدُكُمْ مَا يُحِبُّ فَلاَ يُحَدِّثْ بِهِ إِلاَّ مَنْ يُحِبُّ، وَإِذَا رَأَى مَا يَكْرَهُ فَلْيَتَعَوَّذْ بِاللَّهِ مِنْ شَرِّهَا، وَمِنْ شَرِّ الشَّيْطَانِ وَلْيَتْفِلْ ثَلاَثًا وَلاَ يُحَدِّثْ بِهَا أَحَدًا فَإِنَّهَا لَنْ تَضُرَّهُ ‏"‏‏.‏
Reference : Sahih al-Bukhari 7044
In-book reference : Book 91, Hadith 58
USC-MSA web (English) reference : Vol. 9, Book 87, Hadith 168
  (deprecated numbering scheme)