When the Prophet ﷺ fell ill, some of his wives mentioned a church they had seen in the land of Abyssinia called Mariya. Umm Salama and Umm Habiba had been to the land of Abyssinia, and they spoke of its beauty and the images inside it.He raised his head and said, "Those people, when a righteous man among them died, would build a place of worship over his grave and then make these images in it. Those are the worst of creation in the sight of Allah."
لما اشتكى النبي ﷺ ذكرت بعض نسائه كنيسة رأينها بأرض الحبشة يقال لها مارية، وكانت أم سلمة وأم حبيبة أتتا أرض الحبشة، فذكرتا من حسنها وتصاوير فيها، فرفع رأسه فقال: أولئك إذا مات منهم الرجل الصالح بنوا على قبره مسجدا، ثم صوروا فيه تلك الصورة، أولئك شرار الخلق عند الله.
Bukhari related it in the Book of Funerals (1341), and Muslim in the Book of Mosques (528), both from the hadith of Hisham, from his father, from Ayesha, as previously mentioned, with the wording given by Bukhari. For the remaining hadiths on the prohibition of building mosques over graves, see "Mosques."It has been narrated from Abu Saeed that "the Prophet ﷺ forbade building over the grave," though this is munqati (disconnected). Ibn Majah related it (1564) from Muhammad bin Yahya, who said, Muhammad bin Abdullah Raqashi told us, who said, Wahib told us, who said, Abdul-Rahman bin Yazid bin Jabir told us, from Qasim bin Mukhaymara, from Abu Saeed, as mentioned.Qasim bin Mukhaymara's hearing from any of the companions has not been established, as stated by Yahya bin Main and others. Busiri pointed to this in Zawaid, saying, "This chain has trustworthy narrators, but it is munqati, as Qasim bin Mukhaymara did not hear from Abu Saeed."