There is agreement among the Muslim scholars that the Farewell Tawaf is prescribed by law. Both Muslim and Abu Daw’ud reported from Ibn ‘Abbas that he said, “The people (pilgrims) used to leave Makkah in every other direction (and haphazardly). Thereupon the Prophet (peace be upon him) said, “Let none of you leave Makkah before making a Tawaf around the Ka’bah, as the last of Hajj rites.”
There is disagreement, however, about its legal position. Malik, Dawu’d, and Ibn Al-Munzhir say it is sunnah and by leaving it one does not incur any penalty. Ash-Shafi’i is also of this view. The Hanafi and Hanbali schools, and, according to one report, Ash-Shafi’i, hold that it is obligatory, and a pilgrim who misses it must slaughter an animal to atone for it.