This is the first of five warning passages in the book of Hebrews (2:1-4, 3:7- 4:13, 5:11- 6:12, 10:19-39, 12:14-29). That these warnings are repeated so frequently isn't the most striking feature about them. What is important to note is each warning is strategically placed in the very center of the author's expositions of the greatness of grace through the redemptive priestly ministry of Jesus Christ freely on our behalf.
In other words, these warnings are intentionally married to the passages magnifying divine grace freely bestowed through the shed blood and heavenly intercession of God the Son. So we're meant to learn something important. Warnings aren't contradictory to grace. They are protective of grace. The warnings are set in the middle of the strongest grace passages because warnings are the conduit through which grace is made effective just as the wires in your house are the conduit through which electricity turns on your lights. No wires, no lights.