What does the Bible mean when it says that we are sealed with the Holy Spirit? In the apostle Paul's day, when goods were shipped from one place to another, they would be stamped with a wax seal, imprinted with the signet ring of the owner. This was a unique mark of ownership. People could look at the crate, see its wax seal, and know they had better not open it.
The same was true with a document from a king. It would be sealed in wax and imprinted with the royal seal. People knew if they opened it and were not the intended recipient, they would be endangering their very lives.
In the same way, God has put His royal seal on us: "Now He who establishes us with you in Christ and has anointed us is God, who also has sealed us and given us the Spirit in our hearts as a guarantee" (2 Corinthians 1:21–22). The seal is the presence and work of the Holy Spirit in our hearts and lives. Upon our conversion, we are sealed with the Holy Spirit.
Let's say that a thief wanted to steal a briefcase. Then he notices a nametag on it, bearing the name of a famous boxer. Most likely, the thief wouldn't steal that briefcase. Why? He would be afraid of what would happen. He doesn't want to suffer bodily harm.
The devil wants to come and destroy us as Christians. He wants to wreak havoc in our lives. But he sees our ID tag: "Owned by Jesus Christ. Sealed and insured by the Holy Spirit." So he backs off, because we belong to Jesus Christ.