Why is 'putting to death' condoned in the Bible? Death as Judgement

One of the well known commandments is "Thou shalt not kill." However, it seems that death is the single most used judgement for violations of the Leviticus law.

Not only is killing sanctioned as an act of punishment for egregious violations, being put to death is also commanded for less abhorrent crimes, as in Leviticus 20:11;


  If there is a man who lies with his father's wife, he has uncovered his father's nakedness; both of them shall surely be put to death, their bloodguiltiness is upon them. (NASB)


Death for seemingly unknown reasons

During the Exodus God commanded that Israel slaughter nation after nation. Thousands upon thousands, if not millions, of people were put to death as Israel came in and took over the promised land. Why did God tell Israel to do this?


Can you explain why God commanded Israel to slaughter nation after nation?
To preserve the sanctity of life
Genesis 9:6

Whoso sheddeth man's blood, by man shall his blood be shed: for in the image of God made he man.

The Lord commands that those who commit certain sins must die because they have despised those made in His own image. It's also worth noting that one of the reasons for the flood (where all but 8 were killed) was the attempt to pollute mankind and introduce a demonic likeness (see Nephilim).
As punishment for a nation
Isaiah 13

1 The burden of Babylon, which Isaiah the son of Amoz did see. 2 Lift ye up a banner upon the high mountain, exalt the voice unto them, shake the hand, that they may go into the gates of the nobles. 3 I have commanded my sanctified ones, I have also called my mighty ones for mine anger, even them that rejoice in my highness. 4 The noise of a multitude in the mountains, like as of a great people; a tumultuous noise of the kingdoms of nations gathered together: the Lord of hosts mustereth the host of the battle. 5 They come from a far country, from the end of heaven, even the Lord, and the weapons of his indignation, to destroy the whole land

If a nation ignores warnings from God of impending judgment if they fail to repent of their wicked ways then God must then act in judgment, otherwise how could we believe that any of His promises would stand?
In the passage above we also see evidence the God can use a pagan or unrighteous nation as an instrument of judgment. He also used Israel as an instrument of judgment against the Hittites, Amorites, Canaanites, Perizzites, Hivites, and the Jebusites because of the abominations they had committed.
Rejection of God
Hebrews 10:28

Anyone who rejected the law of Moses died without mercy on the testimony of two or three witnesses.

While the physical death might seem severe, the real punishment is reserved until the dead are judged. This is still the case regardless of whether capital punishment is still in occurring. Though &quot;God is not willing that any should perish&quot;, those who have rejected His offer of mercy will not only die but be cast into the place &quot;where the worm does not die and the fire is not quenched&quot;.
Because He is Sovereign
God allowed the sons and daughters of Job to be killed. Our natural inclination might be to protest that God is unjust (like Job's wife), however Job understood that the Lord is sovereign. Despite restoring a larger number of possessions, God blesses Job with exactly the same number of sons and daughters. When we grasp that our existence on this earth is fleeting we may, like Paul, look forward to the day when we can put off this tent.