Verses 1-29
Psalm 118 A procession of thanksgiving
Originally this hymn was apparently sung by a combination of the temple singers, the congregation and the king, to mark some great national occasion such as a victory in battle. The scene is set in the temple, where the royal procession enters the gates and moves to the altar (see v. 19,20,27).
The singers call Israel to worship, and the congregation responds with praise to God for his steadfast love (1-4). The king then recounts how, in answer to prayer, God saved him from his enemies (5-7). The people respond that God is worthy of people's trust (8-9). The king describes the hopeless position he had been in, with enemies attacking him on every side, but with God's help he overthrew them (10-14). The people respond that God is all-powerful (15-16).
After expressing his confidence in God and his gratitude for God's chastening, the king commands that the temple gates be opened to him (17-19). The gatekeepers open the gates, but add the reminder that only the righteous can enter God's temple (20). The king responds by thanking God for his righteous salvation, for this alone enables him to enter God's presence (21).
The people then sing their rejoicings. When the king had been on the edge of shameful defeat, he seemed like a useless builder's brick that the builders had thrown away in disgust. Now, with his triumph, the same brick seems to have been brought back and made the chief cornerstone, giving perfection and character to the building (22-25).
From the altar in the temple courtyard, the priests sing their welcome as the worshippers, in procession and waving branches of palm trees, draw near. The palm branches give the appearance of binding the worshippers together as they surround the altar in preparation for the sacrifice (26-27). Before the sacrificial ceremony commences, the king, followed by the congregation, offers a final thanksgiving (28-29).