Caution: Translations of Quran and Ḥadīth may lead to possible misapplications and misinterpretations. This site is intended for students of sacred knowledge that are proficient in comprehending classical Arabic and have a strong foundation in Islamic sciences. Also note that religious injunctions rely on several aspects beyond what one may glean through reading individual aḥādīth.
bayhaqi:6463Muḥammad b. ʿAbdullāh al-Ḥāfiẓ > Abū ʿAbdullāh Muḥammad b. Yaʿqūb > Muḥammad b. Ismāʿīl > Abū Ṭāhir > Ibn Wahb > Ibn Jurayj Yḥaddithunā > ʿAṭāʾ b. Abū Rabāḥ

Whenever the wind was stormy, the Messenger of Allah ﷺ used to say: O Allah! I ask Thee for what is good in it, and the good which it contains, and the good of that which it was sent for. I seek refuge with Thee from what is evil in it, what evil it contains, and the evil of that what it was sent for; and when there was a thunder and lightning in the sky, his colour underwent a change, and he went out and in, backwards and forwards; and when the rain came, he felt relieved, and I noticed that (the sign of relief) on his face. 'A'isha asked him (about it) and he said: It may be as the people of 'Ad said: When they saw a cloud formation coming to their valley they said:" It is a cloud which would give us rain" (Qur'an, xlvi. 24). (Using translation from Muslim 899b)   

البيهقي:٦٤٦٣أَخْبَرَنَا مُحَمَّدُ بْنُ عَبْدِ اللهِ الْحَافِظُ أنبأ أَبُو عَبْدِ اللهِ مُحَمَّدُ بْنُ يَعْقُوبَ ثنا مُحَمَّدُ بْنُ إِسْمَاعِيلَ ثنا أَبُو طَاهِرٍ أنبأ ابْنُ وَهْبٍ قَالَ سَمِعْتُ ابْنَ جُرَيْجٍ يحَدِّثُنَا عَنْ عَطَاءِ بْنِ أَبِي رَبَاحٍ

عَنْ عَائِشَةَ زَوْجِ النَّبِيِّ ﷺ قَالَتْ كَانَ النَّبِيُّ ﷺ إِذَا عَصَفَتِ الرِّيحُ قَالَ اللهُمَّ إِنِّي أَسْأَلُكَ خَيْرَهَا وَخَيْرَ مَا فِيهَا وَخَيْرَ مَا أُرْسِلَتْ بِهِ وَأَعُوذُ بِكَ مِنْ شَرِّهَا وَشَرِّ مَا فِيهَا وَشَرِّ مَا أُرْسِلَتْ بِهِ قَالَتْ فَإِذَا تَخَيَّلَتِ السَّمَاءُ تَغَيَّرَ لَوْنُهُ وَخَرَجَ وَدَخَلَ وَأَقْبَلَ وَأَدْبَرَ فَإِذَا مَطَرَتْ سُرِّيَ عَنْهُ فَعَرَفَتْ عَائِشَةُ ذَلِكَ مِنْهُ فَسَأَلَتْهُ فَقَالَ لَعَلَّهُ يَا عَائِشَةُ كَمَا قَالَ قَوْمُ عَادٍ {فَلَمَّا رَأَوْهُ عَارِضًا مُسْتَقْبِلَ أَوْدِيَتِهِمْ قَالُوا هَذَا عَارِضٌ مُمْطِرُنَا} [الأحقاف 24]  

رَوَاهُ مُسْلِمٌ فِي الصَّحِيحِ عَنْ أَبِي طَاهِرٍ

See similar narrations below:

Collected by Muslim
muslim:899bAbū al-Ṭāhir > Ibn Wahb > Ibn Jurayj Yuḥaddithunā > ʿAṭāʾ b. Abū Rabāḥ

Whenever the wind was stormy, the Messenger of Allah ﷺ used to say: O Allah! I ask Thee for what is good in it, and the good which it contains, and the good of that which it was sent for. I seek refuge with Thee from what is evil in it, what evil it contains, and the evil of that what it was sent for; and when there was a thunder and lightning in the sky, his colour underwent a change, and he went out and in, backwards and forwards; and when the rain came, he felt relieved, and I noticed that (the sign of relief) on his face. 'A'isha asked him (about it) and he said: It may be as the people of 'Ad said: When they saw a cloud formation coming to their valley they said:" It is a cloud which would give us rain" (Qur'an, xlvi. 24).  

مسلم:٨٩٩bوَحَدَّثَنِي أَبُو الطَّاهِرِ أَخْبَرَنَا ابْنُ وَهْبٍ قَالَ سَمِعْتُ ابْنَ جُرَيْجٍ يُحَدِّثُنَا عَنْ عَطَاءِ بْنِ أَبِي رَبَاحٍ

عَنْ عَائِشَةَ زَوْجِ النَّبِيِّ ﷺ أَنَّهَا قَالَتْ كَانَ النَّبِيُّ ﷺ إِذَا عَصَفَتِ الرِّيحُ قَالَ اللَّهُمَّ إِنِّي أَسْأَلُكَ خَيْرَهَا وَخَيْرَ مَا فِيهَا وَخَيْرَ مَا أُرْسِلَتْ بِهِ وَأَعُوذُ بِكَ مِنْ شَرِّهَا وَشَرِّ مَا فِيهَا وَشَرِّ مَا أُرْسِلَتْ بِهِ قَالَتْ وَإِذَا تَخَيَّلَتِ السَّمَاءُ تَغَيَّرَ لَوْنُهُ وَخَرَجَ وَدَخَلَ وَأَقْبَلَ وَأَدْبَرَ فَإِذَا مَطَرَتْ سُرِّيَ عَنْهُ فَعَرَفْتُ ذَلِكَ فِي وَجْهِهِ قَالَتْ عَائِشَةُ فَسَأَلْتُهُ فَقَالَ لَعَلَّهُ يَا عَائِشَةُ كَمَا قَالَ قَوْمُ عَادٍ { فَلَمَّا رَأَوْهُ عَارِضًا مُسْتَقْبِلَ أَوْدِيَتِهِمْ قَالُوا هَذَا عَارِضٌ مُمْطِرُنَا}