Praise be to Allah.
Insulting Allaah or Islam is major kufr which puts a person beyond the pale of Islam. Allaah says (interpretation of the meaning):
“Say: Was it at Allaah and His Ayaat (proofs, evidences, verses, lessons, signs, revelations, etc.) and His Messenger that you were mocking?”
66. Make no excuse; you disbelieved after you had believed”
What you have to do is to remind this slanderer and advise him, and warn him that all his good deeds are to no avail, and that if he does not repent, he will meet Allaah when he is guilty of major kufr.
Tell him that the punishment that he deserves in this world is execution, because the Prophet (peace and blessings of Allaah be upon him) said: “Whoever changes his religion, execute him.” Narrated by al-Bukhaari, 3017.
Tell him that he must come back to Islam, and that if he comes back and repents, Allaah will accept his repentance.
If he responds, then all well and good, but if he does not respond, it is not permissible for you to stay with him when he is insulting Islam.
Shaykh Ibn ‘Uthaymeen was asked about the ruling on staying among people who insult Allaah, may He be glorified.
It is not permissible to stay with people who are insulting Allaah, may He be glorified, because Allaah says (interpretation of the meaning):
“And it has already been revealed to you in the Book (this Qur’aan) that when you hear the Verses of Allaah being denied and mocked at, then sit not with them, until they engage in a talk other than that; (but if you stayed with them) certainly in that case you would be like them. Surely, Allaah will collect the hypocrites and disbelievers all together in Hell”
And Allaah is the Source of strength. End quote.
Majmoo’ Fataawa al-Shaykh Ibn ‘Uthaymeen, 2/question no. 238
It should be noted that bad company will bring nothing but evil, so protect yourself against that. The Prophet (peace and blessings of Allaah be upon him) likened a bad companion to the one who operates the bellows: either he will burn your clothes, or you will notice a foul smell from him.
It was narrated from Abu Moosa (may Allaah be pleased with him) that the Prophet (peace and blessings of Allaah be upon him) said: “The likeness of a good companion and a bad companion is that of one who carries musk and one who works the bellows. With the carrier of musk, either he will give you some or you will buy some from him, or you will notice a good smell from him; as for the one who works the bellows, either he will burn your clothes or you will notice a bad smell from him.” Narrated by al-Bukhaari, 5543; Muslim, 2628.
Al-Nawawi (may Allaah have mercy on him) said:
In this hadeeth the Prophet (peace and blessings of Allaah be upon him) likened a good companion to the one who carries musk, and the bad companion to one who works the bellows. It points to the virtue of sitting with righteous, good and honourable people, people of good attitude, awareness, knowledge and manners, and indicates that it is not allowed to sit with evil people and followers of innovation, those who backbite about people or who are foul-mouthed and have nothing better to do, and other blameworthy things. End quote.
Sharh Muslim, 16/178
In conclusion: You have to advise this person who lives with you, who has fallen into major kufr because of his insulting Islam, and who has committed a major sin by insulting you. If he responds to your advice and mends his ways, then stay with him and help him to discipline himself, but if he does not respond, then there is nothing good for you in remaining friends with him.
And Allaah knows best.