Question: The devil has to be insane, doesn't he? Thinking he can defeat God makes him quite mad.
Response: Thank you for your note. Yes, from God's point of view, the devil is, as you say, "mad" - it is surely madness to oppose God. And yet we see that this same sort of madness is the rule for the human race (not the exception), as throughout history people have chosen to reject God and act as if they would live forever on this earth. This is a madness born of arrogance (which corrupts all true thinking). There is, moreover, a great potential benefit to the devil for completely destroying humanity: an end to faith, an end to the chain and line of faith, an end to the plan of God (see part 5 of the Satanic Rebellion series). If he could pull it off, God (according to Satan's thinking) would be forced to acquiesce. At that point, anything might be possible (including the demon-angelic genetic engineering of species that preceded the divine judgment of darkness to which the 7 days of re-creation respond: see part 2 of the Satanic Rebellion series).
But in all these diabolical attempts, God is in charge in the person of Jesus Christ who is blessed forever. Glory be to God for His great victory at the cross and His great victory to come!
On our Lord's victorious return and defeat of Satan at Armageddon, see the following link:
Coming Tribulation part 5: "Armageddon and the Second Advent"
Please also see:
Didn't the devil know he couldn't defeat God?
The Cross, Sin, and the Devil in God's Plan.
Free-Will Faith and the Will of God
Yours in the love of Christ,