Indeed, Islam exhorted Muslims to take care of a sick person and commanded them to visit the sick and invoke Allah for him with speed recovery. Islam set different kinds of invocations that should be said when visiting a sick person, all these because Muslims are like one soul when one of them becomes happy, all should become happy and if one of them feels pain, all should feel pain for him. It was reported in Sahih Al Bukhari and Sahih Muslim on the authority of An-Nu`man ibn Bashir (may Allah be pleased with him) who narrated that the Messenger of Allah (peace be upon him) said: "The believers in their mutual kindness, compassion and sympathy are just like one body. When any limb of it aches, the whole body aches, because of sleeplessness and fever." [Sahih Al Bukhari No. 6011 and Sahih Muslim No. 2586]. Another narration of Imam Muslim: "Muslims are like one body of a person; if the eye is sore, the whole body aches, and if the head aches, the whole body aches." [Sahih Muslim No. 2586].
Therefore, visiting the sick for condolence and alleviating the matter for them was ordained and that has become one of their rights. It was reported in Sahih Muslim on the authority of Abu Hurayrah (may Allah be pleased with him) that the Prophet (peace be upon him) said: "There are six rights of a Muslim upon a Muslim: When you meet him, greet him; when he invites you, accept his invitation; when he seeks counsel, give him advice; when he sneezes and praises Allah, say to him: May Allah have mercy on you (Yarhamuk-Allah); when he is sick, visit him; and when he dies, follow his funeral procession." [Sahih Muslim No. 2162]. There are many narrations on the virtue and the reward of visiting a sick person.
Imam Muslim reported in his Sahih on the authority of Thawban, the freed slave of the Messenger of Allah (peace be upon him), who narrated that the Messenger of Allah (peace be upon him) said: "The one who visits the sick is in fact like one who is in the fruit garden of Paradise until he comes back."
In another narration, he said: "He who visits the sick continues to remain in Khurfat Al Jannah. It was said to him: O Messenger of Allah, what is the meaning of Khurfat Al Jannah? He said: Its gardens." [Sahih Muslim No. 2568].
At-Tirmidhy reported on the authority of Abu Hurayrah (may Allah be pleased with him) that he said: The Messenger of Allah (peace be upon him) said: "Whosoever visits an ailing person or a brother of his to seek the Pleasure of Allah, an announcer (angel) calls out: May you be happy, may your walking be blessed, and may you be awarded a dignified position in Paradise." [Sunan At-Tirmidhy No. 1931, and Al Albany (may Allah bestow mercy on his soul) graded it as good in Sahih At-Targhib No. 3474]; and Hadiths in this regard are numerous].
It is desirable for a Muslim when visiting the sick to comfort him, alleviate the matter for him, remind him of the great reward of Allah, and tell him that sickness is an expiation and purification for his sins.
It was reported in Sahih Al Bukhari on the authority of Ibn `Abbas (may Allah be pleased with him) who said that the Prophet (peace be upon him) went to visit a bedouin who was ill. When the Prophet (peace be upon him) visited someone who was ill, he would say: Never mind, may it (the sickness) be a purification, if Allah wills. I said: A purification! No, rather it is a fever which boils (or appears) in an old man and will cause him to visit the graves. The Prophet (peace be upon him) said: All right then." [Sahih Al Bukhari, No. 5656].
As for his saying: "it will be a purification (from sins), if Allah wills," it means: Purification and expiation for your sins. It was reported in As-Sunan of Abu Dawud on the authority of Um Al `Ala' (may Allah be pleased with her) who said: The Messenger of Allah (peace be upon him) visited me while I was sick. He said: Be glad, Umm Al `Ala' for Allah removes the sins of a Muslim for his illness as fire removes the dross of gold and silver." [Sunan Abu Dawud No. 2688, and Al Albany (may Allah bestow mercy on his soul) graded it as authentic. in Sahih At-Targhib No. 3438].
It was reported in Sahih Muslim on the authority of Jabir ibn `Abdullah (may Allah be pleased with him) who said that the Messenger of Allah (peace be upon him) visited Umm As-Sa'ib (or Umm Musayyab) and asked her: "What ails you, O Umm Sa'ib (or Umm Musayyab)? You are shivering. She replied: It is a fever, may Allah not bless it! He said to her: Do not revile fever, for it cleanses out the sins of the sons of Adam in the same way that a furnace removes the dirt of iron." [Sahih Muslim No. 2575].