And why should you not eat of that upon which the name of Allāh has been mentioned while He has explained in detail to you what He has forbidden you, excepting that to which you are compelled. And indeed do many lead [others] astray through their [own] inclinations without knowledge. Indeed, your Lord - He is most knowing of the transgressors.
Allowing What was Slaughtered in the Name of Allah
This is a statement of permission from Allah, for His servants, allowing them to eat the slaughtered animals werein His Name was mentioned when slaughtering them. It is understood from it that He has not allowed that over which Allah's Name was not mentioned when slaughtering. This was the practice of the pagans of Quraysh who used to eat dead animals and eat what was slaughtered for the idols. Allah next encourages eating from the meat of sacrificed animals on which His Name was mentioned upon slaughtering,
(And why should you not eat of that on which Allah's Name has been mentioned, while He has explained to you what is forbidden to you...) meaning, He has explained and made clear to you what He has prohibited for you in detail,
إِلاَّ مَا اضْطُرِرْتُمْ إِلَيْهِ
(except under compulsion of necessity.) In which case, you are allowed to eat whatever you can find. Allah next mentions the ignorance of the idolators in their misguided ideas, such as eating dead animals and what was sacrificed while other than Allah's Name was mentioned when slaughtering them. Allah said,
(And surely, many do lead astray by their own desires through lack of knowledge. Certainly your Lord knows best the transgressors.) He has complete knowledge of their transgression, lies and inventions.
Ma'arif al-Qur'an
Mufti Muhammad ShafiOn ayahs 118–121
Linkage of Verses
Earlier (116), by saying: وَ اِن تطِع (And if you obey), following people in error was prohibited absolutely. Onward from there, comes the prohibition of such following in a particular matter as necessitated by an event. That event pertains to the lawfulness of what has been slaughtered properly or improperly. The event is that disbelievers tried to put Muslims in doubt by commenting that they did not eat of the animals killed by Allah (i.e. by natural death) while they had no problem with eating of what they killed (slaughtered) themselves (as deduced by Abu Dawud and al-Hakim from Sayyidna Ibn ` Abbas ؓ ). Some Muslims reported this doubt before the Holy Prophet ﷺ Thereupon, these verses ending at: لَمُشْرِكُونَ (121) were revealed (narrated by Abu Dawud and Al Tirmidhi from Sayyidna Ibn ` Abbs as in Al-Lubab).
Whatever there is in the world is all ‘others’ property’ for us, because all of it belongs to God. We have no right to possess or use anything unless it is obtained and utilized in the manner shown by God. This holds good for animals also. Animals provide valuable food for us, but the question arises as to how we acquired the right to use them as food. God creates animals and He alone rears them and brings them to maturity. Then, how does it become permissible for us to use them as our food? Taking God’s name at the time of sacrificing an animal is the answer to this very question. But the taking of God’s name is not a verbal formality. It is, in fact, the recognition of God’s ownership rights over the animal and a demonstration of our gratitude to Him for his gift. Taking God’s name at the time of sacrifice is the symbol of this admission and of our gratitude—the ‘price’ on payment of which an animal in the eyes of our Lord becomes sacrificeable for us. However, one who faces accidental compulsion has been exempted by God from this restriction. When man neglects God’s commands on the subject of what is permitted or prohibited, legal or illegal, superstitions begin to take the place of divine injunctions. On the basis of superstitious ideas, people form divergent opinions. There are some self-devised philosophies behind these superstitions, and on their basis some formalities become established. It is necessary for those who want to become God’s obedient servants to completely give up these superstitions, in practice as well as in theory.
Uthmani text of the Madinah mushaf (King Fahd Complex). Translation: Saheeh International. Tafsir via Quran.com.