It's edifying to understand what the purpose of the 4th commandment was.
Speak thou also unto the children of Israel, saying, Verily my sabbaths ye shall keep: for it [is] a sign between me and you throughout your generations; that [ye] may know that I [am] the LORD that doth sanctify you. Exodus 31:13
Moreover also I gave them my sabbaths, to be a sign between me and them, that they might know that I [am] the LORD that sanctify them. Ezekiel 20:12
Resting in the fact that it is the lord who sanctifies us, and not our own works of self-righteousness, fulfills the righteousness of that law.
Remember the sabbath day, to keep it holy.Six days shalt thou labour, and do all thy work:But the seventh day is the sabbath of the LORD thy God: in it thou shalt not do any work, thou, nor thy son, nor thy daughter, thy manservant, nor thy maidservant, nor thy cattle, nor thy stranger that is within thy gates:
For in six days the LORD made heaven and earth, the sea, and all that in them is, and rested the seventh day: wherefore the LORD blessed the sabbath day, and hallowed it. Exo 20:8
By looking at the parable found in Exodus 20:8-11. We can see that the lamb of God who was slain for the sins of the elect was a work finished within the first six day.
(the creation account) The 7th day is the eternal rest we do enter into. As a parable it is compared to the other rendering of the same commandment found in Deuteronomy 5 .And this time taking a different vantage point to announce the gospel in respect to God moving them Egypt used to typify the sinful world we live in toward the promised land .
Two different renderings but the same reason for each ...the lamb slain from that foundation.The eternal rest form the 7th day.
Keep the sabbath day to sanctify it, as the LORD thy God hath commanded thee.Six days thou shalt labour, and do all thy work:But the seventh day is the sabbath of the LORD thy God: in it thou shalt not do any work, thou, nor thy son, nor thy daughter, nor thy manservant, nor thy maidservant, nor thine ox, nor thine ass, nor any of thy cattle, nor thy stranger that is within thy gates; that thy manservant and thy maidservant may rest as well as thou.
And remember that thou wast a servant in the land of Egypt, and that the LORD thy God brought thee out thence through a mighty hand and by a stretched out arm: therefore the LORD thy God commanded thee to keep the sabbath day ...............(the removal from Egypt account)