Vayikra / Leviticus 17:7
וְלֹא־יִזְבְּחוּ עוֹד אֶת־זִבְחֵיהֶם לַשְּׂעִירִם אֲשֶׁר הֵם זֹנִים אַחֲרֵיהֶם חֻקַּת עוֹלָם תִּהְיֶה־זֹּאת לָהֶם לְדֹרֹתָם׃
And they shall no longer offer their sacrifices to the goat-demons after which they go astray. This shall be a statute forever for them throughout their generations.
Pshat פְּשָׁט
The goat-demons
Rashi: "se'irim" (שְׂעִירִם) are demons, as in the verse "and se'irim shall dance there". Ibn Ezra: they are called so because the body of one who sees them shudders, or because to madmen they appear in the form of goats. And the word "no more" shows that Israel did so already in Egypt.
How Rashi and Ibn Ezra explain it
Remez רֶמֶז
The word "stray"
Malbim: the words "after whom they go astray" (זֹנִים) cover any worship of other gods. Scripture compares a people faithful to its Almighty to a faithful wife, and one who serves another to an unfaithful one. Midrash Lekach Tov: each word at the end of the verse teaches its own lesson: "a statute forever" is said of the Temple, "shall be" means in our time too, "this to them" means without the penalty of karet, "throughout their generations" means that the ban holds always.
How Malbim and Midrash Lekach Tov explain it
Drash דְּרָשׁ
The goat in the wilderness is no offering
Kli Yakar: this law comes right after the chapter on Yom Kippur (the Day of Atonement), so that heretics would not say the goat is sent into the wilderness to the demons. The goat is no offering at all. And one who slaughters outside the Sanctuary for these demons draws the power of the sword and killing, so "blood shall be counted to that man."
How Kli Yakar explain it
Sod סוֹד
To whom the offering is brought
The Zohar: in the field, offerings were brought to the se'irim, they were served and given power. But on Yom Kippur (the Day of Atonement) the goat only carries the wrongs on itself, and the offering is brought to the Holy One, blessed is He, alone, and through it the upper and lower worlds are filled with sweetness. The Zohar, in the section "Ra'aya Mehemna": the se'irim are flawed powers. The goat "shall bear" (וְנָשָׂא) the wrongs as a load, while the Eternal is "bearing" (נֹשֵׂא) iniquity, that is, He lifts this load and takes it away.
How Zohar explain it