Devarim / Deuteronomy 31:18 · Sod
וְאָנֹכִי הַסְתֵּר אַסְתִּיר פָּנַי בַּיּוֹם הַהוּא עַל כָּל־הָרָעָה אֲשֶׁר עָשָׂה כִּי פָנָה אֶל־אֱלֹהִים אֲחֵרִים׃
And I will surely hide My face on that day for all the evil which it has done, for it has turned to other gods.
Sod סוֹד
Walls of mist
At times the Eternal seems far away, as if walls stood between Him and a person. The Ba'al Shem Tov teaches that these walls sometimes only seem to be there, and that even noticing the hiding already changes things.
Ba'al Shem Tov: a king surrounded his palace with walls, fire and rivers, but all of it is an illusion. A wise son understands that his father wants him to come, and boldly walks through them. And more: worst of all is the double hiding, when a person does not know that the Eternal is hidden. One who feels the hiding humbles himself and asks, and for him the hiding is already gone.
How Ba'al Shem Tov explain it
Ba'al Shem Tov And I will surely hide My face
At first glance this is a great wonder: how can it be that the Holy One, blessed is He, would hide His face from Israel, Heaven forbid, and where would they get life and rising, for that is all their life? But here is a parable. A king made several partitions before his palace by illusion, so that no one could enter to him, and hid there. And he made walls, fire and rivers, all by illusion, before his sons. And whoever was wise set his heart to it: how can it be that a merciful father would not want to show his face to his beloved sons? This is nothing but an illusion: the father wants to test whether the son will strive to come to him, and in truth there is no hiding at all.
And as soon as the son gave himself over, at the risk of his life, to enter the river, the illusion vanished and he crossed it. And so with all the partitions, until he came to the king's palace. And there is a fool who is afraid to begin crossing the partitions, and there is one who crosses the water and turns back because of the walls and the fire. And the meaning of the parable is known.
Ba'al Shem Tov And I will surely hide My face
I heard from my master, my grandfather, of blessed and holy memory: "And I will surely hide". For when a person does not know that there is hiding, it is surely not good: he thinks he is a perfect tzaddik and does not return to the Eternal. But when he knows that there is hiding and feels it in his soul, then he humbles himself before the Blessed One and asks of Him. And this is "And I will surely hide": the hiding itself I will hide, and it will not be known that it is hiding. (Degel Machaneh Ephraim, in the collections on the portion Tzav, and the books Ben Porat Yosef, Tzafnat Pa'neach and Keter Shem Tov.)
Takeaway
The second passage was written down by the grandson of the Ba'al Shem Tov, author of the book Degel Machaneh Ephraim. "My master, my grandfather" is what he calls the Ba'al Shem Tov.
The doubled word "surely hide" here is two layers: the Eternal is hidden, and the very fact that He is hidden is hidden. When a person learns of the hiding, the first layer is already removed.
Onkelos renders "hide My face" as "remove My Shechinah" (סַלָקָא אֶסַלֵק שְׁכִנְתִּי). The Ba'al Shem Tov reads the same verse as a test: the father hides so that the son will seek.