In the name of God, Most Gracious, Most Merciful
Peace be upon you,
A difficult question for those who believe in God to answer is, "If God is just and merciful, why does He afflict innocent children?" This question has been asked in many forms by atheists and those who believe alike. For example, the common “Problem of evil” is a broader version of this question.
The Quran tells us that Satan is solely responsible for evil and such calamities; they reflect Satan's incompetence as a designated temporary ruler of this world. Satan is trying very hard to make his kingdom, this world, perfect, but he just can't do it.
God gave us free will (Quran 33:72), and with that free will comes the ability to choose either evil or good. It is not free will if God forces us all to do only good or forces us to love or worship him.
God does not inflict an atom's weight of injustice (Quran 4:40).
Divine Justice
[Quran 4:40] GOD does not inflict an atom's weight of injustice. On the contrary, He multiplies the reward manifold for the righteous work, and grants from Him a great recompense.
Article: Deformed, Retarded, Famine-stricken children
Peace.