That is a good question and the answer is more involved than one might think. I can think of at least two reasons why God chose to kill the firstborn sons instead of Pharaoh.

1) God wanted to make an EXAMPLE out of Pharaoh. Let’s read Exodus 9:13-16, “Then the LORD said to Moses, ‘Rise early in the morning and stand before Pharaoh, and say to him, Let My people go, that they may serve Me, for at this time I will send all My plagues to your very heart, and on your servants and on your people, that you may know that there is none like Me in all the earth. Now if I had stretched out My hand and struck you and your people with pestilence, then you would have been cut off from the earth. But indeed FOR THIS PURPOSE  I HAVE RAISED YOU UP, that I may show My power in you, and that My name may be declared in all the earth’” (NKJV). It is clear from this passage that God could have killed Pharaoh (and all his people) with pestilence, but he allowed him to live so He could manifest His power and declare His name throughout the world. So, the Lord used Pharaoh as an example to show to the entire world what happens when a man (who hates God and refuses to obey Him) hardens his heart and resists the power of God. Pharaoh thought “his gods” were just as powerful as Israel’s God, but God would display to Pharaoh and the world that “there is none like Me in all the earth” (verse 14).

2) God wanted to JUDGE the false gods of Egypt. In Exodus 12:12 we read, “For I will pass through the land of Egypt on that night, and will strike all the firstborn in the land of Egypt, both man and beast; and against all the gods of Egypt I will execute judgment: I am the LORD.” Here we learn that the death of the firstborn sons was not only a judgment upon Pharaoh, but also upon “the gods of Egypt.” This is reiterated in Numbers 33:4, “For the Egyptians were burying all their firstborn, whom the LORD had killed among them. Also ON THEIR GODS the LORD had executed judgments.” There were actually two false gods that were judged in this plague: MIN, the “god of reproduction”; and ISIS, the “goddess of love who protected women and children at childbirth.” This judgment revealed these “gods” were powerless to prevent the omnipotent God from slaying the firstborn sons. Of course we know that these “gods” were not real, but in the minds of Pharaoh and the Egyptians they were real. They worshipped them and trusted in them to act on their behalf. God’s judgment on the firstborn sons manifested the absurdity of worshipping and trusting in imaginary, impotent “gods.”

Before we close this meditation, I believe a word is in order regarding the “innocent children” that you referred to. It is reasonable to assume that many of the firstborn sons were indeed “innocent”; that is, they were either babies or very young children. But let’s remember that every child born into this world is BORN IN SIN. King David expressed this truth in Psalm 51:5, “Behold, I was brought forth in iniquity, and in sin my mother conceived me.” Every member of the human race has inherited the SIN NATURE of Adam, the one who introduced sin into this world. “….by one man’s disobedience many were made sinners” (Romans 5:19). They were “innocent” (in that they had not sinned nor were they capable of understanding what sin is), yet in time they would lose their innocence and become WILLFUL SINNERS. If this had happened and they died without availing themselves of God’s salvation (like Pharaoh and most of his people), they would have been lost for all eternity. Yet we know that if one dies as an “innocent child” (before the age of accountability) they will be saved and go to heaven. This is confirmed in Matthew 18:10-11, “Take heed that you do not despise ONE OF THESE LITTLE ONES, for I say to you that in heaven their angels in heaven always see the face of My Father who is in heaven. For the Son of Man has come to save that which was lost.” Little children are BORN LOST, but Christ went to the cross to “save that which was lost.” When we look at the death of the “innocent children” involved in that last plague in the light of this passage we can say, “It was a mercy that God took them to heaven instead of them growing up with the very real possibility of worshipping false gods and rebelling against the one true God like Pharaoh and many others did.” Perhaps this could be looked upon as a THIRD REASON for God killing the firstborn sons instead of Pharaoh.  (391.5)  (DO)