His life is spared only because disbelief is the decisive condition for the permissibility of shedding the blood of one who has been overpowered. Even a Muslim who takes up arms may be fought, yet once he is captured it is not lawful to kill him, for Islam itself affords protection. In the hadith: “The blood of a Muslim who testifies that there is no god but Allah and that Muhammad is the Messenger of Allah is not lawful to shed except in three cases: disbelief after Islam, adultery after marital consummation, or killing a soul for which he is killed in retaliation.” (1) A narration to the same effect is likewise traced back to the Prophet ﷺ on the authority of Ibn Masʿūd.
Hence, if the combatant is a disbeliever, it is permissible to kill him; and if he is taken prisoner, it is likewise permissible to execute him for his prior hostility (2) and to avert his future harm—for if he is granted clemency or ransomed