Cry out to your God! Turn to God when you need him. The problems that threatened David may have been Absalom’s rebellion (as in Psalm 3), his persecution by Saul, or possibly famine (see verse 7). God does not promise his people a problem free life as long as we live in this world that is under the curse, but he does want you to cry out to him. Turn to the Lord in your distress. Cry out to him with the knowledge that he does hear and answer. Cry out, knowing that the Second Adam offered prayers and petitions with loud cries and tears during his work on earth, Hebrews 5:7,8.
Understand the character of your God. Understanding the character of your God makes a profound difference in how you live each day. He is righteous. Even the opening petition makes clear that there is a connection between the righteousness of God and that of his people. The connection between God’s righteousness and yours is found by faith–and involves the offering of right sacrifices. David is looking ahead by faith to the One who is the sacrifice for the sins of his people. In the face of the delusional idolatry of verse 2, David points you to God’s setting apart of his people, verse 3. Skeptics doubt, but David points you to the covenantal faithfulness of the Lord, echoing the Aaronic benediction, verse 6. He provides abundantly for your needs, v. 7.
Trust your God. Because you trust him, do not sin in anger. Beware of the connection between anger and sin. Anger need not be sinful in itself (God is angry, and there is righteous anger), but we often cross into sin when we are angry. And anger is a murderous sin, as Jesus taught, that violates the image of God. In Ephesians 4 Paul looks at what it means to be renewed in the image of Christ. He focuses on the accomplishment of salvation in the opening part of the chapter, and concludes with an emphasis on God’s forgiveness in Christ. (Salvation is all of grace!) Among the specific changes involved in being renewed in the image of Christ, is dealing with anger in a God-glorifying way. He puts a time limit on dealing with your anger–by sundown, by the end of the day. Don’t pollute a new day with unresolved anger.
Then you can lie down in peace. You lie down in peace because the anger of God against your sins has been propitiated by his providing the perfect sacrifice of his Son. Objective peace now exists between you and God. That provides the security you need. The troubles and challenges are real, but David and Paul (and you) share the confidence that God does secure you. The problems may not have vanished–but you approach them, not as a victim of chance, but as one who is under the care of your faithful Savior. “Yes, my heart is fixed, O Lord, my heart is fixed; Jesus is my hope and righteousness, the Lord will hear me when I call. And henceforth will I both lay me down in peace and sleep securely in Jesus, accepted in the Beloved; for this is the rest wherewith the Lord causeth the weary to rest, and this is the refreshing.” (C. H. Spurgeon, The Treasury of David, [quoting Hawking] on Psalm 4:8.)
If you look at this Psalm as a cure for insomnia, you’re missing its richness. But as you know the peace that David experienced (and you can know it more fully than he did), you can lie down in peace and sleep at the end of the day. Curing insomnia is not a matter of a ritual at bed time, but rather of living each day trusting in the One who is your righteousness.