All perfect praise be to Allah, The Lord of the Worlds. I testify that there is none worthy of worship except Allah, and that Muhammad is His slave and Messenger.
Scholars held different opinions regarding the ruling on the Witr prayer. The majority of scholars: the Maliki, Shafi’i, and Hanbali scholars, believed that the Witr prayer is a confirmed Sunnah and not obligatory, but Abu Haneefah held that it is obligatory.
Al-Mawsoo‘ah Al-Fiqhiyyah reads:
“The majority of scholars held that the Witr prayer is a confirmed act of Sunnah and not obligatory as evidenced by the fact that the Prophet said: “Allah, The Exalted, is Witr (One) and Loves Witr (i.e., that which is odd-numbered) and He loves Witr prayer. Pray Witr, O people of the Quran.” Moreover, he performed it regularly.
They inferred that the Witr prayer is not obligatory from the following authentically reported Hadeeth. A Bedouin asked the Prophet : “What are the religious obligations required of me?” He said: “Five obligatory prayers in a day and night.” The man further asked, “Are there any other prayers due upon me?” The Prophet said: “No, unless you wish to perform voluntary prayers.”
Furthermore, it was narrated on the authority of ‘Abdullah ibn Muhayreez that a man from Banu Kinanah who was called Al-Mukhdaji heard a man in Ash-Sham, nicknamed Abu Muhammad, saying that Witr prayer was obligatory. Al-Mukhdaji said: “In the morning, I went to ‘Ubadah ibn As-Samit . I met him while he was on his way to the Masjid and told him what Abu Muhammad said. ‘Ubadah said: “Abu Muhammad is wrong. I heard the Messenger of Allah say: “Five prayers are those that Allah, The Exalted, has prescribed for (His) servants, whoever does them, and does not neglect any of them out of disregard toward them, will have a promise from Allah, The Exalted, that He will admit him to Paradise. And whoever does not do them will have no such promise from Allah; if He wills, He will punish him and if He wills He will admit him to Paradise.”
‘Ali said: “Witr prayer is not obligatory like the five daily prayers. It is rather an act of Sunnah prescribed by the Prophet . Abu Haneefah contrary to his two companions, and the Hanbali scholar Abu Bakr held that Witr prayer is Wajib (i.e., a religious obligation proved by presumptive evidence) and not Fardh (i.e., a religious obligation proved by precise and absolute evidence). Witr prayer was considered Wajib, being a slightly lesser degree than the Fardh because denying the obligation of Witr prayer does not constitute an act of Kufr (disbelief), and performing it does not require proclaiming the Adhaan like the five daily prayers. He brought forth as supportive evidence the following Hadeeths. The Prophet said: “Witr prayer is a religious duty, so he who does not offer it, is not one of us!” He repeated it thrice. He also said: “Allah, The Exalted, has endowed you with an extra prayer which is better for you than the red camels (high breed camels); perform it after ‘Ishaa’ prayer and up till Fajr prayer.” The wording of the Hadeeth indicates that it is an obligation. There are many hadeeths that command Muslims to perform Witr prayer.”
Allah knows best.