The wives of the Prophet ﷺ joined together out of jealousy over him, so I said to them, "Perhaps his Lord, if he divorced you, would replace you with wives better than yourselves" [Tahrim 66:5], and then this verse was revealed.
حدثنا عمرو بن عون حدثنا هشيم عن حميد عن أنس قال قال
اجتمع نساء النبي ﷺ في الغيرة عليه فقلت لهن {عسى ربه إن طلقكن أن يبدله أزواجا خيرا منكن} فنزلت هذه الآية