There are a lot of Hadith's and many contradict each other. Apostacy laws are barbaric and should be discarded or reinterpreted. Christianity and Judaism has done so. Time for Islam.
Apostasy: Thought Crime in Judaism, Christianity and Islam
Apostasy is the act of leaving a religion. It is
deconversion. Normally it involves taking up another religion and sometimes it involves the taking up of a stance
skeptical of all religions. If deconversion is the result of no longer believing that gods exist, then, the result is
atheism. "
Heresy" is the holding of beliefs that central religious authorities (or
mobs) deem to be unacceptable. Religions often engage in a lot of internal suppression in these matters, subjecting their own followers to careful scrutiny to make sure that they are not merely believers, but, that they believe precisely the
correct things. Dominant monotheistic religions often consider heresy to be the same as apostasy because they reject the concept of diversity or freedom of thought. Neil Kressel in his book on religious extremism lists "
the willingness to implement violent sanctions against those who leave the fold"" as one of religion's most dangerous attributes (out of three)
1.
They have often made deconversion and heresy punishable by death, especially in historical Judaism and Christianity, and it still continues in present-day Islam.