Why did God kill people in the Old Testament?

  •  God is loving, but also just, which explains why Jesus needed to die to take the sins of the world, rather than sins being simply forgiven.
  •  In the Old Testament, God did either kill people, or ordered the Israelites to do so.
  • The Ten Commandments can thus be seen as a personal guide of action, rather than a generic rule that everyone must live by.
  • Remember that the whole of creation operates within the great controversy between good and evil - God's plan was never to kill people, that only happened within the context of sin and in the New Jerusalem sin and death will be ended.
  • While we can at least sometimes know the general context of actions, the Bible does not always go into every specfiic detail - God's exact reasons in any action may be partially known and at least partially unkown.
  • Remember that God is also an advocate of mercy, as He listened to Lot who was trying to plead for the lives of those in Sodom and Gommorah.
  • Whilst we have finite knowledge, God knows virutally infinitely more information than us - He knows what the socities he destroyed were doing and were going to do and whether the people in it were going to repent or not and what would best utilmately for destroying evil, to restore the world back to the Edenic paradise.

 

Reference: https://www.gotquestions.org/God-killing.html.