Ibn Shihab (may Allah have mercy on him) said: If the heretic (zindiq) denies (it) and evidence is established against him, he is to be killed; but if he comes of his own accord, confessing and repentant, he is spared from being killed.
Hadith Referenceالسنن الكبرى للبيهقي / كتاب المرتد / 16854