Psalms 18:21 Meaning: What David Meant When He Said He Kept God’s Ways
For I have kept the ways of Yahweh, and have not wickedly departed from my God.
For I have kept the ways of the Lord, and have not wickedly departed from my God.
For I have kept the ways of Jehovah, And have not wickedly departed from my God.
For I have kept the ways of Jehovah, And have not done wickedly against my God.
For I have kept the ways of Jehovah, and have not wickedly departed from my God.
Meaning in one sentence
David’s bold claim of keeping God’s ways raises questions about his later sins. Discover how this verse speaks to integrity and points to Christ.
Context
Psalm 18 is a royal thanksgiving. David wrote it later in life, after God delivered him from Saul and from many other enemies. He looks back on God’s faithfulness through years of danger. In verses 20, 24, David does something striking: he speaks openly about his own righteousness before God. He is not boasting. He is testifying that God’s deliverance was not random, God was responding to David’s sincere devotion. The surrounding verses show that David kept God’s judgments before him and did not turn away from His statutes. This claim of integrity is not a claim to perfection, but to a heart that stayed loyal to Yahweh through all the trials.
Key Words
Three English phrases carry the weight of this verse. “Kept the ways”, the word “kept” in Hebrew (not available here, but the sense is clear from the commentaries) means to guard, watch over, protect. David did not just know God’s ways; he guarded them as something precious. “Ways of Yahweh” refers to the path God commands, the lifestyle He prescribes. David walked that path even when it cost him. “Wickedly departed” is a strong phrase: it pictures a deliberate, rebellious turning away, not a stumble, but a desertion. David is saying he did not commit treason against his God. He did not abandon the covenant. This is the language of loyalty, not sinlessness. He is honest about his failures elsewhere (Psalm 51), but here he affirms the overall direction of his life: he stayed with God.
How Christians Read This Verse
Christians across traditions have read this verse with care. Reformed commentators like Calvin and Matthew Henry see David’s integrity as real but not absolute, David’s heart was sincere, yet he still needed mercy. Gill (Baptist) points out that these words find their fullest meaning in Christ, who kept God’s ways perfectly. The Cambridge Bible notes that David does not claim a sinless righteousness, but “single-hearted sincerity,” and suggests the psalm was likely written before his great fall with Bathsheba. Across these views, Christians agree: David’s words reflect a genuine, though imperfect, devotion that God delights in, and they point forward to the perfect obedience of the Messiah.
A common misunderstanding
Some readers think David is claiming he never sinned, and then point to his sins with Bathsheba and Uriah. In fact, David is not claiming sinless perfection. The word “wickedly departed” means a complete, final turning away, apostasy. David stumbled and sinned grievously, but he did not abandon God. He repented. This verse is about the direction of his life, not the absence of failure. It is a profession of loyal love, not a boast of flawless behavior.
Living This Out
This week, consider the difference between a stumble and a departure. You might fail God in a moment of weakness, that is real sin, and it requires confession. But have you left the path entirely? Have you stopped wanting Him? David’s words invite you to check your heart’s direction. Are you still guarding God’s ways, even when you fall? He does not ask for perfection, but for persistence. When you sin, run back to Him. That is keeping the way.
Main takeaway: David’s claim of keeping God’s ways is a testimony of loyal devotion, not sinless perfection, and it points to Christ who kept the way perfectly for us.
For Families
For ages 5, 8
David said he kept God’s ways. That means he tried to obey God every day. He did not run away from God. You can keep God’s ways too by listening to Him and saying sorry when you make mistakes.
For ages 9, 12
David is not saying he was perfect. He made big mistakes later in life, and he was very sorry. But here he says he did not wickedly depart from God, that means he never completely turned away. His heart stayed with God. Think about your own heart: are you still following God even when you mess up? That is what matters to Him.
Questions People Ask
Did David claim to be sinless in Psalm 18:21?
No. David is claiming that he did not willfully forsake God or break His covenant. He is not saying he never sinned. The phrase 'wickedly departed' means a complete rebellion, not every stumble. In other psalms, David confesses his sins freely (Psalm 51). Here he is affirming his overall loyalty to God.
How does this verse point to Jesus?
Many Christian commentators see David as a type of Christ. Jesus perfectly kept God's ways without any sin or failure. David's words are partially true of him, but fully true of Christ. Jesus is the one who never wickedly departed from His God, and His perfect obedience is credited to believers.
What does 'wickedly departed from my God' mean?
It means a deliberate, sinful abandonment of God. The Hebrew expression (as explained by Keil & Delitzsch) is 'malitiosa desertio', a malicious desertion. It is not a momentary failure but a conscious choice to turn away from God and His ways in rebellion. David says he did not do that.
Why does David talk about his own righteousness?
David is responding to his enemies' accusations. They claimed he was a rebel and a sinner deserving death. David appeals to his integrity before God to show that his suffering was not punishment for secret wickedness. He is defending God's justice, not bragging about his own goodness.
Was this psalm written before or after David’s sin with Bathsheba?
The superscription places this psalm 'in the day that Yahweh delivered him from the hand of all his enemies, and from the hand of Saul', events early in his reign. Most conservative commentators believe it was written before the Bathsheba incident (see Cambridge Bible). This helps explain why David speaks so confidently of his integrity.
For pastors & researchers
Hebrew interlinear, 8 commentaries & word study