David, hiding from God for over a year, had his sin laid bare to him and all of Israel. David’s story is in 2 Samuel 11 and 12, but it’s his prayer in Psalm 51 that changed the ending. Below is a simple heart outline of his prayer.
Have mercy upon me, O God. David began with humility of need and an unwillingness to make excuses. He had done the rationale game for over a year. Now it was time to come clean.
For I acknowledge my transgressions. David owned his sin, and it was between him and God. “Against You, You only, have I sinned.”
You are blameless when You judge. David knew he needed mercy, he knew it was his sin, but even more important, God was just in His judgment.
You desire truth in the inward parts. David knew His deliverance was in his honesty and God’s mercy.
Wash me, and I shall be whiter than snow. David exalted the Lord and His ability to cleanse, heal, and deliver.
Make me hear joy and gladness. David knew the Lord was gracious, and he asked for the abolition of his sin.
Create in me a clean heart, O God, and renew a steadfast spirit within me. David understood this was a heart issue that only God could change.
Do not cast me away from your presence, and do not take Your Holy Spirit from me. David revealed his restored value and love when he said, the one thing I cannot live without is You and Your presence.
Restore to me the joy of Your salvation. David wanted the joy of the Lord’s salvation restored, not his circumstances. Salvation upheld by the generous Holy Spirit.
Then I will teach transgressors Your ways. David knew restoration would release evangelism of the ways of God in mercy.
Deliver me from the guilt of bloodshed, O God. David would rise without regret and with praise on his lips.
The sacrifices of God are a broken spirit. David acknowledges that religion, and its sacrifices would not impress God, only a broken and contrite heart.
Do good in Your good pleasure to Zion; build the walls of Jerusalem. David now prays for Zion, Jerusalem, and God’s grace to be extended.
David’s prayer, forged in his heart over seven days of humbling himself in prayer to God, restored him to God and removed his wicked ways from him. David rose a free man. He would instruct his elders in the goodness of God and His grace. David would comfort Bathsheba, his wife, and God would give them a son, Solomon by name, whom the Lord loved. David’s darkest hour gave dawn to God’s greatest glory, of mercy, restoration, and redemption.