The majority of the scholars say that prostrations for the “‘ayyat of sajdah” are sunnah for the one who recites the ‘ayyah and for the one who hears it. This is based on what al-Bukhari recorded from ‘Umar who recited an-Nahl upon the minbar one Friday, until he came to the “‘ayyah of sajdah,” and he descended from the pulpit and prostrated along with the people. On the next Friday, he recited the same and when he came to the ‘ayyah of sajdah, he said: “O people, we have not been ordered to prostrate. Whoever does so has acted correctly, while, there is no sin upon one who does not do so.” In another narration it is stated: “Allah has not forced upon us the sajdah but if one wishes to do so (he may make a prostration.)”
In addition, the group, except for Ibn Majah, records that Zaid ibn Thabit said: “I recited an-Najm to the Prophet sallallahu alehi wasallam and he did not prostrate during it.” Ad-Daraqutni records it and observes: “None of us prostrated during it.”
Ibn Hajar al-Asqallani says that the strongest opinion is that he left it to show that it is permissible not to do it. Shaf’i holds a similar view. This opinion is supported by what is recorded by al-Bazzar and adDaraqutni from Abu Hurairah who says: “The Prophet sallallahu alehi wasallam recited an-Najm and prostrated and we prostrated with him.” (In Fath al-Bari, Ibn Hajar holds that its narrators are trustworthy.) Ibn Mas’ud moreover reported that the Prophet sallallahu alehi wasallam recited anNajm and prostrated, and all of the people with him prostrated, save one old man from the Quraish who simply lifted some pebbles or dirt to his forehead and said: “That is sufficient for me.” Ibn Mas’ud said: “After [some time] I found that he was killed while still an unbeliever.” This is recorded by al-Bukhari and Muslim.