Psalm 139 is one of the most sublime chapters in the book of Tehillim. Ibn Ezra opens his commentary with the words: "This psalm is exceedingly sublime regarding the ways of Hashem, and in all these five books there is no psalm like it" - meaning, in all five books of Tehillim there is no psalm equal to it. He adds: "And according to a person's understanding of the ways of Hashem and the ways of the soul, so will he contemplate its meanings" - each person will understand the deeper themes of this psalm according to the level of his contemplation of the ways of Hashem and the soul within man. "And now I will explain it briefly with Hashem's help."
The Malbim defines the subject of the psalm: "This psalm speaks of glorious matters concerning divine knowledge and providence" - not only Hashem's knowledge of man, but also His providence over him. As explained at length in Rav Chaim Friedlander's Siftei Chaim, individual divine providence (hashgachah pratit) means orchestrating tests for a person according to his exact spiritual state: his condition is constantly assessed, and trials are presented to him accordingly. The Holy One, blessed be He, has knowledge of everything - even a gnat, even a tiny worm under a tree. Yet the essence of Hashem's knowledge of man, which we define as hashgachah pratit, is to observe his progress and present him with challenges tailored to his standing.
לַמְנַצֵּחַ לְדָוִד מִזְמוֹר יְהֹוָה חֲקַרְתַּנִי וַתֵּדָע׃ - For the conductor, a psalm of David: Hashem, You have searched me and known me.
Hashem searches the heart and kidneys, knowing all my secrets - everything occurring within my heart of hearts is known to Hashem. So Radak explains: "You have searched my heart and known it," as the verse states, "I, Hashem, search the heart and test the mind."
The Malbim explains that there are two types of knowledge here, which from a human perspective appear paradoxical, yet in the presence of the Holy One, blessed be He, they are one. This paradox, mentioned on several occasions, is the age-old problem of divine foreknowledge and free will. On one hand, there is primordial knowledge: Hashem knows the entire future with absolute, flawless certainty, free of any doubt, independent of time, location, or contingent possibilities. Hashem's knowledge of what a person will do tomorrow is not subject to conditions - there is no "if he is in this place, then yes; if at that time, then yes." The Holy One, blessed be He, knows what a person will do tomorrow, in a year, in a decade, and in a thousand years, with absolute clarity.
On the other hand, seemingly in direct contradiction: despite this foreknowledge, man is entirely free in his actions. From the standpoint of free will, David says, "You have searched me and known me" - You search me now to know what I have chosen through my own free will, even though You already knew it beforehand. As it were, the Holy One, blessed be He, perceives in real time what man chooses to do, even though for Him it was already known. This raises the classic question: if Hashem knew in advance that a certain person would desecrate the Sabbath, and that outcome could never change because Hashem's knowledge is absolute, why is he held accountable and punished? Seemingly he could not have chosen otherwise, since Hashem's prior knowledge was completely unalterable.
The Rambam addresses this very paradox, writing that human intellect cannot grasp this concept, for "His knowledge is not like our knowledge." The Raavad critiques him, arguing that he did not follow the practice of the wise, for if one raises a troubling question without providing an adequate resolution, one risks giving rise to skepticism or heresy, Heaven forbid - so why raise the issue at all? This has been addressed in detail on several occasions: in the study of Rav Friedlander's Siftei Chaim, in a full lesson following chapter 12 of Sefer Iyov on the subject of foreknowledge and free will, and in Pirkei Avot on the Mishnah, "All is foreseen, yet permission is granted." The crucial point to understand is that there is no contradiction, and Hashem's foreknowledge does not compel our actions. Even though Hashem knows beforehand what we will choose, the choice remains entirely free. The internal awareness a person feels that it is in his power right now to decide whether to do something or not is not an illusion; it is truth and reality. For that reason, a person must ultimately give an accounting for all his deeds, because in truth his choice was free. Whoever wishes to explore how this reconciles with Hashem's foreknowledge may consult those sources and lessons.
אַתָּה יָדַעְתָּ שִׁבְתִּי וְקוּמִי בַּנְתָּה לְרֵעִי מֵרָחוֹק׃ - You know my sitting down and my rising up; You understand my thought from afar.
Radak explains that here David mentions human movement: sitting down and standing up. By his own will a person sits, and by his own will he rises. And what did he do to rise or to sit? He merely thought in his heart, "I want to sit," and he sits down; "I want to stand," and he stands. A person's inner desire and thought are known to the Holy One, blessed be He, beforehand, and this is the meaning of "from afar" - even from afar, Hashem already understood it.
And what is the meaning of lere'i? According to the Radak, this is not from the root of re'a, a friend or companion, but from the root of ra'ayon, a thought or idea: "You understand my thoughts from afar" - You understood my thought and knew it long in advance. I only just now thought of getting up, yet You, Hashem, knew this long before.
Rashi, on the other hand, explains that re'i is related to "This is my beloved and this is my friend [re'i]": "You understood from afar" - You observed from afar to draw me to Your companionship and Your affection, so that I would become, as it were, a companion to You, moving toward connection and friendship even from afar. "Lere'i" - to draw me close to You. In its simple sense, re'utecha is not only friendship, but also desire or will, as in the Aramaic phrase di vera chire'utei ("which He created according to His will"), meaning toward Your will and Your love. Both interpretations harmonize: a person's will is directed toward his companion - I want to be with my friend, I want to draw close to my companion.
The Malbim explains that human actions fall into four categories, and the psalm enumerates them. There are voluntary actions that a person performs without deliberate intellectual choice, such as sitting and standing - "You know my sitting and my rising." And there are actions that a person contemplates beforehand, deliberating over how to act - these are deliberate choices, the product of the intellect, and concerning them it is said, "You understand my thoughts from afar," referring to my reflections and plans. Even before I conceived the idea and chose whether to act one way or another, You already understood it from afar.
When we say "without deliberate intellectual choice" - after all, everything ultimately stems from the intellect, even when lifting a cup and setting it down. The point is that there is no deep deliberation here over whether to move the hand right or left, or whether to sit or stand. There is no conscious selection in the sense of "I weighed my options and chose this," but rather an action carried out automatically: I wanted to, so I stood up; I wanted to, so I sat down. By contrast, deliberate actions are those where one reflected and consciously chose a specific course, and regarding them as well, "You understand my thoughts from afar."
אׇרְחִי וְרִבְעִי זֵרִיתָ וְכׇל־דְּרָכַי הִסְכַּנְתָּה׃ - "You winnow my path and my lying down, and You are familiar with all my ways."
The third category consists of natural bodily actions, such as eating and sleeping, and concerning them it is said: "You winnow my path and my lying down, and You are familiar with all my ways." Rashi explains: my paths and my resting places - riv'i being related to lirboa, to lie down - and my dwelling You have surrounded with a partition, such that nothing can be done without Your knowledge. "Zerita," according to Rashi, is related to "a border [zer] of gold around it": You have encircled me, as it were, and I cannot make any movement or perform any action without You, Hashem, knowing it.
Our Sages expounded this verse in reference to the reproductive drop, teaching that the child is formed from the purest part of it - from its finest component. "Zerita," according to this, comes from the term for winnowing (zoreh), as one winnows into the wind, which is a method of sorting and selecting. And "riv'i" is from the language of intimacy and mating (lirboa). Thus, already from that moment, the Holy One, blessed be He, drew forth the soul of man from what was finest in that drop.
"And You are familiar with all my ways" [vechol derachai hiskanta] - meaning You have taught, or You have learned; You know all my ways intimately. The Radak explains that "orchi" is my walking during the day, as in "a wayfarer [holech orach]," and "riv'i" is when I lie on my bed at night, from the root of lying down (lirbotz), resting at night - as the Targum translates vatirbatz as verav'at. According to this, the verses mention four basic bodily movements of man: sitting and rising, walking and lying down. "You know my sitting and my rising" refers to sitting and standing, while "my path and my lying down" refers to walking and resting. He likewise explains "zerita" as related to surrounding, like "a border [zer] of gold around it": You know all my movements and thoughts because You encompass my body and my thoughts at all times. And "vechol derachai hiskanta" - You have become accustomed; You know all my ways as someone who is thoroughly accustomed to something and therefore knows it, so are You intimately familiar with me and know all my ways.
The Radak quotes the sage in Sefer HaKuzari: "So should a person reflect that all his limbs are arranged with wisdom, order, and precise measure, and he sees them obey his will, though he does not know which of them must be moved. For instance, he wishes to stand up, and he finds all his limbs acting as obedient helpers that have already raised his body, without his even knowing which limbs did so." In other words, if one reflects upon this, what an immense kindness of Hashem it is that we do not need to issue conscious commands to the body; rather, it all happens beneath conscious thought. A person wants to stand up - and he stands up; he does not give a conscious order to the body and wait for it to process the instruction. The moment he desires something, all his limbs stand ready at his command, without his having to address them directly. The same is true when one wishes to walk, to sit, or any other movement. And about this it is said: "You winnow my path and my lying down, and You are familiar with all my ways."
The Radak cites another explanation in the name of his father: Orchi is related to achor (behind), as in "You have formed me back and front" (achor vakedem tzartani), and riv'i relates to the four directions (arba ruchot). That is, what is before me and what is behind me, to my right and to my left, above me and below me - all directions. And zerita is related to "I will scatter to every wind" (ezreh lechol ruach): in this, You encompass all six directions around me. The meaning is that the Holy One, blessed is He, surrounds me in every direction, whether behind me, in the four directions, above me, or below me.
The Ibn Ezra explains that the verse refers back to physical sensations, to the senses - the sense of touch, the sense of taste, the sense of sight, to all five senses: that whatever one organ performs, another organ does not, and You have measured and distributed this throughout the human body.
The Malbim also explains that zerita implies encircling a person like a wreath (zer), knowing all of man's actions. It also mentions the actions man is accustomed to: "You are familiar with all my ways" (vechol derachai hiskanta) - You have habituated me to those actions, to all bodily functions. When one reflects upon this, it is truly a wonder: no one ever gave an infant a course on how to nurse and eat, yet as soon as a baby is born, it already knows how to feed; it possesses an instinctual reflex. Logically, where did this reflex come from? Who taught it how to eat? Until this point, it was nourished through the umbilical cord, so how does it suddenly know? About this it is said: "You are familiar with all my ways" - You accustom me to all my ways; all my actions and all my paths stem from what You have taught me and habituated within me in advance, even without any effort of my own.
כִּי אֵין מִלָּה בִּלְשׁוֹנִי הֵן יְהֹוָה יָדַעְתָּ כֻלָּהּ׃ - For there is not a word on my tongue, but behold, Hashem, You know it all.
The Radak explains: When the word is not yet on my tongue, before I have even begun to speak, You already know everything. That is, not only the thought itself, but the Holy One, blessed is He, already knows what you intend to say. "Behold, You know it all" - even before I open my mouth, You know everything that will be spoken.
Rashi offers an explanation that is the most straightforward understanding: it is not within my tongue's power to express what is in my thoughts, yet You know what will emerge from my mouth even if I myself did not realize I thought it. At times, a person plans to say one thing and something entirely different comes out, as King Solomon said, "To man belong the preparations of the heart, but from Hashem comes the reply of the tongue" (Mishlei 16:1). History is full of politicians making slips of the tongue - intending to say one thing and accidentally saying the exact opposite. For example, during an election debate interview, a speaker was asked about Jerusalem and mistakenly stated he was in favor of "a united Netanyahu" instead of a united Jerusalem. In other words, a person thinks one thing and something else comes out; he intends to say one thing and something else leaves his mouth. Thus, I myself cannot always express what I think, yet You, Master of the Universe, know what will emerge from my mouth even if I had not contemplated it in my heart. This is what is meant by "To man belong the preparations of the heart, but from Hashem comes the reply of the tongue" - a person may formulate many plans in his heart, but what ultimately leaves his lips comes from Him, blessed be He.
The Malbim adds here the fourth category, the matter of speech: while there is not yet a word on my tongue, You already know everything, including everything I am destined to say.
אָחוֹר וָקֶדֶם צַרְתָּנִי וַתָּשֶׁת עָלַי כַּפֶּכָה׃ - You have formed me back and front, and laid Your hand upon me.
Rashi explains: "Back and front" (achor vakedem) refers to my front and my back. "And laid Your hand upon me" (vatashet alai kapecha) relates to Your pressure and mastery over me, in the sense of "for his mouth urges him on" (achaf alav, Mishlei 16:26) - that is, the Holy One, blessed is He, as it were, rules over man and governs him.
The Radak cites in the name of his father that this refers to the formation of the fetus in its mother's womb: "You have formed me" (tzartani) stems from tzurah (form) - You fashioned me. "And laid Your hand upon me" (vatashet alai kapecha) is like what is written in Iyov, "and curdled me like cheese" (Iyov 10:10): You placed Your hands upon me and fashioned me like cheese, through a process of kneading and molding, just as cheese is formed. "And laid [Your hand] upon me" means You shaped this precisely according to the proper length and stature I ought to have.
Our Sages also state that Adam was created stretching from one end of the world to the other, and the Holy One, blessed be He, reduced him to one hundred amot. Where is this hinted at? In our verse. "Behind and before You formed me" - from one end of the world to the other, from the latest to the earliest. "And laid Your palm upon me" - the letter kaf has the numerical value of one hundred; He laid His hand upon him and reduced him to one hundred amot. This does not refer to a hundred physical amot, for our Sages do not occupy themselves with crude physical matters, but rather that He diminished his spiritual perception and comprehension.
The Malbim explains: Not only do You possess knowledge of every detail of man's actions - which is the theme of the entire psalm according to the Malbim, to demonstrate Hashem's knowledge of all human deeds - but You also exercise dominion over every movement of his limbs and every activity. I am, as it were, enveloped by Hashem's sovereignty, like a person surrounded on all sides by an army: from behind, from before, from above, and from the flanks - like a small city, representing man, under siege from every direction. Man cannot flee from Hashem, neither forward nor backward. And if he were to think, "I will flee upward," the verse says, "and laid Your palm upon me" - You hem me in from above as well. As it were, man has no movement without Hashem and cannot do anything without His will. Accordingly, "tzartani" does not derive from the root of creation, but from the root of siege (matzor): You have besieged me behind and before.
The book Tehillot Maharitz explains that the Holy One, blessed be He, created man to be a mehalech - one who moves: he cannot remain in the same state, in the same reality, and in the same mode all the time; rather, he must always be advancing and perfecting himself further, or Heaven forbid the reverse, declining. One of the great Chassidic masters once remarked: What do we learn from a bicycle? A person cannot stand still; he must keep pedaling. If you stop pedaling, you fall. This is the reality of human existence: one must always be in motion. One can travel backward or travel forward, but one must be in motion. No one can say, "I stayed the same; I have been the same for a decade." There is no such thing as staying the same. Either you advanced or you regressed. This is the meaning of "Behind and before You formed me": either a person moves backward and, God forbid, descends into the pit of destruction, or he advances forward. Hashem created man this way - either backward or forward; there is no standing still.
Our Sages expounded further on the words "Behind and before You formed me": If man merits, he is told, "You preceded all the works of Creation"; and if he does not merit, he is told, "The gnat preceded you" - the gnat was created before you in the order of Creation. At first glance, this exposition is puzzling, as discussed in the lessons on the weekly Torah portions: How can one say that if a person merits, he preceded all the works of Creation? That is surely not factually so, for whether he merits or not, man was created last! Moreover, what does "meriting" have to do with this? Is it a lottery?
Rather, the masters of Mussar explained that the word zachah ("merited") is related to zikuch - he refined and purified himself. Man is the crown of Creation and the purpose of Creation. If man truly upholds that purpose and walks the path charted for him by the Master of the Universe, then he indeed preceded the works of Creation. Note that "preceded" here is not chronological, for the gnat certainly preceded him in time. Rather, "preceded" means that "Let us make man" was said for your sake - you were at the foundation of the blueprint.
This can be compared to a builder designing an apartment building: he plans it for residents he has never met, knowing that people will eventually move in and need a kitchen of specific dimensions, a pantry of a certain size, a bedroom, a children's room, a living room, windows, fresh air, sunlight, and a bathroom. He designs everything for the sake of the resident, yet the resident has not arrived yet - he will arrive only at the end, after the building is fully constructed, furnished, and ready. But who was in mind first? The human being. The builder did not create all this for the sake of the plaster, the cinderblocks, or the rebar, but for man. Imagine the plasterer coming along and saying, "Sir, I was here long before you; you only just arrived!" The resident replies, "My friend, I was the one envisioned in the blueprints; who was even looking at you? This entire home was designed for me; everything here exists for my sake." This is the meaning of "You preceded all the works of Creation": if you merit - if you refine yourself and truly conduct yourself as a human being - the entirety of Creation was created for you.
However, if you do not merit, then you are not fulfilling the role of man; and if you are not truly a human being, you are merely another animal; and if you are just an animal, then "the gnat preceded you," for the gnat was created on the fifth day and you on the sixth. After all, the gnat does not need everything you need: it does not need a house, it does not need windows, it does not need sunlight, it does not need air - it manages without all that. You, however, require all of this, which is a sign that you are human, and if you are human, you preceded all the works of Creation. But if you do not conduct yourself as a human being, you are merely another zoological species, and then indeed the gnat preceded you.
Thus, "you preceded" means "last in deed, first in thought" - you were envisioned in thought when the world was created, and therefore you came first, even if technically you arrived only at the end. A king does not arrive while there is still concrete and mortar lying about; the king arrives once the palace is polished and fully established. In this manner, the Holy One, blessed be He, created man in his exalted stature, arriving at the very end - and coming last is by no means a deficiency. But if one merely behaves like an animal, then other animals were here before you.
פְּלִיאָה דַעַת מִמֶּנִּי נִשְׂגְּבָה לֹא־אוּכַל לָהּ׃ - Such knowledge is too wondrous for me; it is exalted, I cannot attain it.
In the sefer Emet Keneh, Rav Mazuz explains that the phrase "and laid Your hand upon me" alludes to the matter that when an infant is born, an angel comes and strikes him on his mouth, causing him to forget the Torah he had learned. This is hinted at in the following verse: "Such knowledge is too wondrous for me; it is set on high, I cannot attain it" - all that knowledge that I once had has now become exalted beyond me; this knowledge has left me and is beyond my reach. And by virtue of what? By virtue of "and laid Your hand upon me" - through the strike delivered by the angel, that knowledge vanished from him.
Psalm 139 is, in the words of the Ibn Ezra, the exalted psalm with no peer across all five books of Tehillim, and is dedicated - as the Malbim defines it - to Hashem's knowledge and His providence. David enumerates every category of human activity: voluntary actions ("my sitting down and my rising up"), choices of the heart ("You discern my thoughts from afar"), natural habits ("my path and my lying down"), and speech ("there is not a word on my tongue") - and in all of them, Hashem's knowledge precedes man and surrounds him like a crown on every side, to the point that "You have fashioned me back and front," and man possesses no movement without Hashem. From this emerge two fundamental principles: that Divine foreknowledge does not negate free will and personal responsibility for one's actions, and that man - if he purifies himself and walks in the path outlined by his Creator - is the one who preceded all the works of Creation, for everything was created for his sake; but if not, a gnat preceded him. And just as man was created in the aspect of a traveler, who must never stand in one place but continually advance, so too must he pedal forward, achieve personal perfection, and reclaim for himself that very knowledge that was "set on high" beyond him when he emerged into the world.