Where there are mountains, there must also be valleys - it's a simple fact of the created world. The same is true in our spiritual life. To reach the place where God is leading us, we must sometimes traverse "the valley of the shadow of death" (Psalm 23:4).
Spiritual mountaintops are wonderful spots to rest awhile. As such times, we feel close to God and sure of His love. But we get to those high places by toiling through the valley, where we discover His character, the truth of His promises, and our own weakness. There are aspects of the Lord that we see only as we journey through shadow.
God is a jealous shepherd - He wants His followers relying entirely upon Him. He draws us through valleys in order to remove every habit, thought pattern, or external crutch that we use instead of trusting Him. In the low places, those suddenly seem inadequate. We discover whether our faith, courage, and wisdom are self-created or from the Lord.
While walking in valleys is an inevitable part of life, believers aren't left comfortless. Verse 5 is about having needs met, including the desire to be soothed. Here is the image of a tender shepherd rubbing oil onto an animal's scraped skin. God promises assurance, healing, and safety, even in hardship.
Believers can shout, "I trust God," from the mountain because they have learned to live by faith in the valley. Walking in the shadow of evil is difficult and frightening work. But when we surrender to whatever the Lord has to teach us in this dark place, our spirit is quieted and our faith is strengthened.