"So the LORD said to Moses: 'See I have made you as God to Pharaoh, and Aaron your brother shall be your prophet. You shall speak all that I command you. And Aaron your brother shall tell Pharaoh to send the children of Israel out of his land. And I will harden Pharaoh's heart, and multiply My signs and My wonders in the land of Egypt. But Pharaoh will not heed you, so that I may lay My hand on Egypt and bring My armies and My people, the children of Israel, out of the land of Egypt by great judgments. And the Egyptians shall know that I am the LORD, when I stretch out My hand on Egypt and bring out the children of Israel from among them.' Then Moses and Aaron did so; just as the LORD commanded them, so they did" (Exo. 7:1-6).
Although Moses was 80 years old and Aaron was 83, they boldly obeyed God! We learn here that there were two reasons for the plagues: (1) To bring Israel out of bondage in a powerful way, and (2) To educate the Egyptians so they would know that Israel's God was true. This reminds me of 12:12 where God describes the tenth plague (i.e., the death of the firstborn) and affirms that He would execute judgment "against all the gods of Egypt." As we study the ten plagues, we must remember that Egypt was a polytheistic society. They worshiped over 80 gods! In fact, the influence of religion was strongly seen in Egypt in literature, government, art, and about everything else except morality! They deemed many animals to be sacred, including: lions, oxen, rams, wolves, dogs, cats, vultures, falcons, hippopotami, crocodiles, cobras, dolphins, frogs, locusts, etc. Additionally, they worshiped anthropomorphic gods like Osiris. Even Pharaoh himself was considered a god. These plagues would not just be against Pharaoh and his people but "against all the gods of Egypt"! Each one of the plagues was a direct insult to the gods of Egypt (cf. 18:10,11)! We will elaborate on this as we consider each plague.
"Then the LORD spoke to Moses and Aaron, saying, 'When Pharaoh speaks to you, saying, 'Show a miracle for yourselves,' then you shall say to Aaron, 'Take your rod and cast it before Pharaoh, and let it become a serpent.'" So Moses and Aaron went in to Pharaoh, and they did so, just as the LORD commanded. And Aaron cast down his rod before Pharaoh and before his servants, and it became a serpent. But Pharaoh also called the wise men and the sorcerers; so the magicians of Egypt, they also did in like manner with their enchantments. For every man threw down his rod, and they became serpents. But Aaron's rod swallowed up their rods. And Pharaoh's heart grew hard, and he did not heed them, as the LORD had said" (7:8-13).
This event and the following plagues may be looked upon as a contest between Israel's God and the Egyptian gods. What Aaron did was incredible but somehow the Egyptian magicians imitated it! No doubt they knew what was expected of them when they were summoned and they came equipped to impress with their "enchantments." My understanding here is that they did not truly possess miraculous power; they were simply excellent magicians (in the modern sense of the term). Even today there are "cane to snake" tricks performed by magicians (e.g., please consult the book Strictly Visuals by David Ginn, p. 25). We don't know how long it took for the magicians to show up or if this was a trick they had done previously and didn't require much prep, but they would have been surprised by the ending (i.e., when Aaron's rod swallowed all of their serpents)! This showed the supremacy of Jehovah, but Pharaoh was not moved.
Although many affirm that the Egyptian magicians performed genuine miracles via Satan's power, I do not believe such is the case because of what it would imply. If the devil possessed supernatural power and was able to perform miracles, then how could mankind ever be able to genuinely confirm God's word (cf. Mark 16:20)? Since the purpose of the apostolic miracles, for example, was to confirm their message as both true and from God, how could any message truly be confirmed if it were possible that the devil was behind a certain miracle? It is true that Satan is sometimes granted authority by God to do certain works (e.g., Job 1 & 2), but generally speaking, I believe his "miracles" are counterfeit and full of fraud and lies (cf. John 8:44; II Thess. 2:9-12).