Psalm 107 is a detailed outpouring of thanks to the Almighty for delivering those in distress. Commentators have discussed the historical background of this poetic expression of appreciation. The language of the psalm suggests that it was recited at a large gathering after deliverance from various tribulations, and many suggest that the chapter refers to the Exodus from Egypt. Indeed in the Sephardi liturgy, this chapter is recited over Pessah. Other commentators suggest that that the psalm is depicting King David's ordeals. A third opinion reads it in reference to the return to Zion after the destruction of the First Temple and the Babylonian Exile. Finally, others understand the psalm to be foretelling the thanks we will give at the final redemption. In this vein, the chapter is recited at the opening of the Yom Ha'atzmaut evening prayer service. The Talmud, however, is less concerned with its historical underpinnings, focusing instead on the contemporary application of this paradigmatic psalm. Thus our sages, referencing the various verses of the psalm, conclude that four people must give thanks once the danger they are experiencing has passed (B. Brachot 54b): First, seafarers who have safely reached their destination must express their gratitude. Second, those who have journeyed through a wilderness must also show their appreciation. The commentators discuss what type of journey warrants the recitation of the blessing. Some say that the benediction is only mandated after a dangerous journey through an area fraught with bandits and wild animals. Others say that the term "wilderness" is used by the sages following the psalmist, but really the completion of any journey should be followed by a blessing of appreciation. Jewish law records both opinions but requires a minimum journey of one parsa (less than five kilometers), unless the route is particularly dangerous (Shulhan Aruch OH 219:7). The blessing need not be said until the completion of the journey, thus it is not recited at a way station (Rabbi Israel Meir Hakohen of Radin, 19th-20th century, Poland). The third person who should recite a benediction of thanks is one who was ill and has recovered - here too the authorities are divided on the type of illness that warrants the benediction. The fourth person is one who was incarcerated and subsequently released. According to one authority, only one who was imprisoned and facing the death penalty need recite the blessing (Rabbi Avraham Abele Gombiner, 17th century, Poland). Others suggest that release from any detention should be followed by the benediction of thanks (Rabbi Israel Meir Hakohen). Is it only in these four scenarios that one must give thanks? Authorities are divided on whether to expand this list to include others who have experienced deliverance. In the least, we may suggest that these four items are models of those who should express their appreciation (Maharal, 16th century, Central and Eastern Europe). The seafarer represents those who are being attacked by forces greater than them. Wayfarers are those who find themselves distanced from their comfort zones with no access to means of protection. The sick battle illness that is within their own bodies and do not grapple with an outside enemy. The prisoner is one whose adversary is a fellow human who denies freedom. Thus the four categories are broader than the specific talmudic descriptions. Indeed the codifiers have ruled that anyone who has experienced a miraculous escape should recite the benediction of thanks, although in deference to the opinions that the list is a closed inventory, the blessing should be recited without using the Almighty's name (Shulhan Aruch OH 219:9). Notably missing from this list are those who were almost endangered (Maharal). While in such scenarios it is certainly appropriate to be grateful that no evil befell you, it is nevertheless unnecessary to recite the benediction. After identifying those who must give thanks, the talmudic passage continues to outline the form and forum of this expression of gratitude. Appreciation is shown by reciting a blessing that concludes with the words "who bestows beneficial kindness." Many rabbinic authorities record a different text for the benediction: "Who bestows good upon the undeserving, who bestowed every goodness upon me." Those present then respond: "May He who bestowed upon you every goodness, [continue to] bestow upon you every goodness forever." (Shulhan Aruch OH 219:2 following earlier sources). While most blessings are recited privately, this benediction has a required stage - it must be pronounced in the presence of 10. Both the form and the forum of giving thanks can be traced back to the psalm. After each section of the psalm detailing a different ordeal, there is a poetic refrain: And they cried out to God in their trouble; He delivered them from their distresses... Let them thank God for His kindness, and let them announce His wonderful works to the children of humans. Just as we cry out for the Almighty's assistance, we are instructed not to forget God's hand when we are delivered. This chorus embodies the two requirements delineated by the sages: "Let them thank God for His kindness" reflects the obligation to express gratitude as reflected by the language of the blessing; and "let them announce His wonderful works to the children of humans" suggests the requirement that this is done in the public forum of a prayer quorum. The psalm ends with a call: Whoever is wise, let them consider these things, and let them meditate on the kindnesses of God (Psalms 107:43). Following on from this verse Nahmanides (13th century, Spain-Eretz Yisrael) makes a surprising assertion: "The intent of all the commandments is that we believe in the Almighty and we thank God, our creator." This, suggests Nahmanides, is the purpose of all creation: "The Almighty God desires naught from these lower worlds, except that humans will know and appreciate God who created them." Thus the purpose of prayer and of gathering in synagogues to pray together is to thank God and to publicly acknowledge and announce the role of God in our lives. The writer is on the faculty of Pardes Institute of Jewish Studies and is a rabbi in Tzur Hadassah.