Jabir reported: “The Prophet, peace be upon him, forbade the whitewashing of a grave, sitting on it, or erecting any structure on it.” (Reported by Ahmad, Muslim, Nasa’i, Abu Daw’ud, and Tirmizhi who said that it is a sound hadith) Tirmizhi reported this hadith with this wording: “The Prophet, peace be upon him, forbade the whitewashing of graves, writing on them, building on them, or stepping on them.” Nasa’i, reported it in these words: “The Prophet, peace be upon, forbade building over a grave, adding anything to it, white washing it, or writing on it.”
The majority of scholars interpret this prohibition as an expression of disapproval, while Ibn Hazm takes it to mean that the act is unlawful. The wisdom behind it is that a grave is not made to last forever, but is sure to disintegrate with the passage of time. whitewashing graves is decorating them with the beauty of this world for which the dead have no need. Others think that its wisdom lies in the fact that whitewashing is done by burning gypsum (brimstone): This view is supported by a narration of Zaid bin Arqam who said to a person who wanted to build something over his son’s grave and whitewash it: “You are wrong and have done a useless thing. Nothing touched by fire should be brought near the grave.” There is nothing wrong, however, in daubing it with clay. Tirmizhi said: “Some scholars, including Al-Hasan alBasri, hold it permissible to coat the graves with clay.” Ash-Shafi’i is also of the same view and sees no harm in giving the graves a coating of clay.
Ja’far bin Muhammad reported from his father: “The grave of the Prophet, peace be upon him, was raised one hand from the ground and was coated with red clay and some gravel.” This was narrated by Abu Bakr An-Najjad, but AlHafiz did not comment on this in his ai-Talkhis.
The scholars also disapprove of building graves with bricks or wood or burying the dead with a coffin unless the burial ground was wet or soft. If it is wet or soft, then it is permissible to use bricks and the like and to place the body in a coffin. It is reported from Mughirah that Ibrahim said: “The scholars preferred bricks of clay and straw, but disliked clay bricks; they preferred bamboo and disliked wood.”
Concerning the hadith prohibiting writing on graves, it apparently includes writing the name of the deceased or any other thing on the grave. AlHakim commented on this hadith and said: “Though its chain of narrators is sound, in practice, however, it was not followed.” Many Muslims from the East and the West do write on the graves. This is a practice that was passed on from one generation to the next. Azh-Zhahabi said: “This hadith is an innovated one, and no prohibition is genuinely reported.”
The Hanbali school holds that inscription on graves is prohibited, whether it is a portion of the Qur’an or the name of the deceased.” The Shafi’i school agrees with this ruling, but they also hold: “If the grave is of a scholar or a righteous man, it is preferable to write his name on it to make it known.”
The Maliki school holds that writing any portion of the Qur’an is not permissible, but writing the name and date of death of the deceased is disliked (makruh).
The Hanafi school disapproves of writing anything on the grave and considers it unlawful, except when it is feared that any trace of the grave might disappear. Ibn Hazm said: “It is not disapproved if the name of the deceased was engraved on a rock.”
It is forbidden in a hadith “to add more soil than what was taken out when digging the grave.” Al-Baihaqi has dealt with this under a separate chapter entitled, “No adding of soil to the grave in excess of what is taken therefrom.”
Ash-Shawkani said that: “Adding apparently here means adding more soil than what was taken out while digging the grave.” Some interpreted the addition to a grave as making a grave over another one. Ash-Shafi’i preferred, however, the first interpretation, saying that it was preferable not to add more soil than what was taken out while digging the grave which is preferred lest the grave be raised high. So long as the additional soil does not raise the grave higher than the ground, there is nothing wrong with it.