His threats against them resulted only in an increase in their faith and submission to Allah, for the veil of disbelief had been lifted from their hearts and the truth became clear to them because they knew something that their people did not: that what Musa had done could not have been done by any human being unless Allah helped him, making it proof and an evidence of the truth of what he had brought from his Lord. Then Fir`awn said to them:
ءَامَنتُمْ لَهُ قَبْلَ أَنْ ءَاذَنَ لَكُمْ
(You have believed in him before I give you leave.) meaning, `you should have asked my permission for what you did, and you did not consult with me; if I had given you permission you could have done it, and if I did not allow you, you should not have done it, for I am the ruler and the one to be obeyed.'
They said, "There is no harm. We are to return to our Lord. (26:50)
When the Pharaoh threatened the magicians to kill them, and to cut their limbs and to crucify them, the magicians replied rather indifferently, the gist of their reply was, ` You do whatever you can. We shall lose nothing. Even if we are killed we will go back to our Lord, where there is nothing but comfort'.
It is worth noting here that the magicians who had involved all their lives practicing the sinful sorcery and who believed in the Pharaoh's claim to be a god, rather, used to worship him, pronounced faith in Allah before that tyrant and despotic king and the entire nation. This was in itself something most astonishing and courageous, but it was not just the pronouncement of faith in Allah, but a demonstration of such deep devotion as if they could see the Dooms Day and the Hereafter before their eyes. The blessings and bounties of the Hereafter were within their sight, for which they raised themselves over and above any punishment or torment of this world, and said فَاقْضِ مَا أَنتَ قَاضٍ that is ` You do whatever you are to do (20:72). We are not going back from our faith'. This in fact was also a miracle of Sayyidna Musa (علیہ السلام) which was no less than the miracle of the staff and the luminous hand. Many incidents of similar nature have also occurred with our Holy Prophet ﷺ . In one such incident a drastic change had occurred in a seventy years old infidel in that within a minute he not only converted to Islam, but was ready to lay down his life to become a martyr.
Tazkirul Quran
Maulana Wahiduddin KhanOn ayahs 48–50
The magicians threw down their ropes and sticks, and the spectators felt as if these ropes and sticks had changed into snakes and were running along the ground. But this was not a real change. It was simply an optical illusion, whereas, the changing of Moses’s rod into a snake was a miracle of God. So when Moses’s rod became a snake and started moving along the ground, it instantly nullified the spell cast by the magicians. Thereafter, the magician’s ropes and sticks reverted to being the ropes and sticks that they actually were. Earlier, the magicians had considered Moses to be a magician like themselves. But, the aforesaid experience opened their eyes. They were well versed in the art of magic. So, they immediately understood that this was not magic but prophethood. However, it was possible that they could have refused to accept the Truth and, like Pharaoh, could have uttered some falsities in order to reject Moses. But, it is impossible for a man who is intellectually alive not to accept the Truth when it fully reveals itself before him. The magicians were persons who were alive in this manner. So, they immediately accepted Moses’s truthfulness.
Uthmani text of the Madinah mushaf (King Fahd Complex). Translation: Saheeh International. Tafsir via Quran.com.