That day the LORD saved Israel from the hands of the Egyptians. Exodus 14:30a (NLT)
Then God gave the people all these instructions. Exodus 20:1 (NLT)
When Israel was enslaved in Egypt, the first thing God did was to free them from their bondage. He established a relationship with them letting them know he would protect them, provide for them and that he loved them. Then, he taught them what it would mean to live in obedience (the Ten Commandments) to him. God knows that trying to follow a bunch of rules without being in relationship to him will lead to rebellion. Obedience to God has to come from a place of love. We often get that wrong. We think we need to be perfectly obedient before we come to Jesus. We don’t. God shows us his love first so we will fall in love with him. Then he says ‘follow me’.
We love him, because he first loved us. 1 John 4:19 (NLT)