There is no basis for the hadith, “Every deed may be either accepted or rejected except sending blessings upon me.”
Question

There is a hadith that is well-known in the country in which I live, and it is attributed to the Prophet (blessings and peace of Allah be upon him): “Every deed may be either accepted or rejected except sending blessings upon me.” They write it in public places without mentioning the source of the hadith. How sound is this hadith?
Praise be to Allah.After researching the matter, we have not found any trace of the hadith mentioned in the question: “Every deed may be either accepted or rejected except sending blessings upon me.” It is not mentioned by any of the hadith scholars, scholars of tafseer or fuqaha’ in the sources we were able to check, and we have not come across anything to suggest the same meaning in the saheeh Prophetic Sunnah.
Rather it is most likely that this is a fabricated hadith that is falsely attributed to the Prophet (blessings and peace of Allah be upon him), and it is possible that it was fabricated in recent times, and includes meanings that are wrong and false. Sending blessings upon the Prophet (blessings and peace of Allah be upon him) is one of the most virtuous of deeds and one of the most beloved of deeds that draw one closer to Allah, but the probability of it being accepted or rejected is the same as all other righteous deeds. The Prophet (blessings and peace of Allah be upon him) said: “Whoever does an action that is not part of this matter of ours, it will be rejected.” Narrated by Muslim (1718).
It was narrated that Abu Umaamah al-Baahili (may Allah be pleased with him) said: A man came to the Prophet (blessings and peace of Allah be upon him) and said: What do you think, if a man joins a military campaign, seeking reward and renown? What will he get? The Messenger of Allah (blessings and peace of Allah be upon him) said: “He will not get anything.” He repeated the question three times, and the Messenger of Allah (blessings and peace of Allah be upon him) said to him: “He will not get anything.” Then he said to him: “Allah does not accept any deed except that which is done sincerely for His sake alone, seeking His pleasure.” Narrated by an-Nasaa’i (no. 3140); classed as saheeh by al-Albaani in Saheeh an-Nasaa’i.
In fact, many of those who send blessings upon the Prophet (blessings and peace of Allah be upon him) will have those blessings rejected, because their motive is to show off and seek renown, or they include innovated phrases, or because there is some impediment to acceptance in the one who is sending blessings upon the Prophet (blessings and peace of Allah be upon him). Allah, may He be glorified and exalted, says (interpretation of the meaning):
{Indeed, Allah only accepts from the righteous [who fear Him]} [al-Maa’idah 5:27].
And Allah knows best.