All perfect praise be to Allaah, The Lord of the Worlds. I testify that there is none worthy of worship except Allaah and that Muhammad is His slave and Messenger.
The hadeeth that reads, “…Any man from my ummah whom I have cursed…” does not apply to every person whom the Prophet cursed; rather, it applies to every person whom he had cursed while he was angry and that person did not deserve to be cursed. Anas narrated the following:
“There was an orphan girl with Umm Sulaym, so the Prophet saw that orphan girl and said, 'O, is that you! You have grown up. May you not advance in years!' The girl returned to Umm Sulaym weeping. Umm Sulaym said, 'O daughter, what is the matter with you?' She said, 'The Prophet of Allaah has invoked Allaah that I should not advance in years, so now I will not advance in years.' Umm Sulaym went out wrapping her head-dress hurriedly until she met the Prophet . He said to her, 'Umm Sulaym, what is the matter with you?' She said, 'O Prophet of Allaah, have you invoked Allaah against my orphan girl?' He said, 'Umm Sulaym, what is that?' She said, 'She (the orphan girl) claims that you have invoked Allaah that she should not advance in years.' Thereupon, the Prophet smiled and said, 'O Umm Sulaym, do you not know that I have made this condition with my Lord. And the condition with my Lord is that I said to Him: I am only a human being and I feel pleased just as a human being feels pleased and I become angry just as a human being becomes angry, so for any person from my ummah whom I supplicate against and he in no way deserves it, let that, O Lord, be made a source of purification and nearness to You (Allaah) on the Day of Resurrection.'” [Ahmad and Muslim]
An-Nawawi said:
“I have made this condition with my Lord. And the condition with my Lord is that I said to Him, 'I am a human being and I feel pleased just as a human being feels pleased and I become angry just as a human being becomes angry, so for any person from my ummah whom I supplicate against and he in no way deserves it, let that, O Lord, be made a source of purification and nearness (to You).' These ahaadeeth clarify how the Prophet was merciful to his nation and looked after their benefits, protected them, and tried to achieve all what benefits them. The above narration clarifies what is meant with the other general ahaadeeth; that his supplication against the person will be a mercy, an expiation, a purification, and so forth if that person does not deserve that supplication against him, and insulting him and cursing him, and the like, provided he is a Muslim. Otherwise, the Prophet supplicated against the non-Muslims and hypocrites, and it was not a mercy for them. If it was said how is it that he supplicated against people who do not deserve that supplication or that he insulted them or cursed them and the like, then the answer is the one given by the scholars, the summary of which is of two meanings: one is that what is meant is that he does not deserve that in the sight of Allaah and in reality, but according to what appears to us he deserves it, so it appears to the Prophet that such a person deserves it based on an Islamic inference (evidence) while in reality he does not deserve that, and the Prophet is ordered to judge by the appearance of the people [what appears to him from the people] while Allaah knows what is in their hearts. The second meaning is that the cursing and supplication against the person is not intended; rather, this is the custom of the Arabs in their speech without intention, such as their saying ‘taribat yadaak’ (may your right hand be damned) and ‘aqra halqa’ (may you be wounded and find pain in your throat), and as in the hadeeth in question ‘may you not advance in years’, and in the hadeeth by Mu’aawiyah ‘may Allaah not satiate his stomach’, and so forth. They do not intend to mean this very supplication, but the Prophet feared that this would be answered by his Lord, so he asked Him that this be a mercy, expiation, closeness, purity and reward. This happened to him rarely, at very odd times, as the Prophet was never obscene in his speech, and he was never cursing, or taking revenge for himself, and it was previously stated in this hadeeth that he was asked to supplicate against the tribe of Daws, and he supplicated in their favor, saying, 'O Allaah, guide the tribe of Daws.' He also supplicated, 'O Allaah, forgive my people as they do not know.'”
On the other hand, al-Munaawi said:
“This (considering the curse a mercy) has caused confusion because he cursed many people, among whom is the person who makes images, the one who takes taxes, the one who attributes himself to other than his father, the muhallil (one who makes a woman lawful to her former husband by marrying her just for the sake of divorcing her afterwards in order to make her lawful to her ex-husband), the thief, the one who drinks alcohol, the one who consumes riba (interest), and others, so the scholars argued that by virtue of this interpretation those would get mercy and purification as well! The answer is that what is meant here is whomever the Prophet cursed while he was angry while that person did not deserve it; the evidence for this is that the hadeeth states: any man whom I curse while I am angry; and in a narration by Muslim, 'I am only a human being and I feel pleased just as a human being feels pleased and I become angry just as a human being becomes angry, so for any person from amongst my ummah whom I curse and he in no way deserves it, let that, O Lord, be made a source of purification and nearness.' As regards the person whom the Prophet cursed and who committed a prohibition, then he is not included in this [the hadeeth does not apply to him, and mercy, purity, reward does not apply to him].”
Allaah knows best.