If he commands an act of disobedience, then he is not to be obeyed, for he himself is a servant of Allah, commanded by Allah. How, then, can he command what contradicts Allah’s command? We say: Our Lord and your Lord is Allah, and you are never to be obeyed in disobedience to Allah.
Evidence for this is the account of the detachment sent out by the Messenger of Allah, peace and blessings be upon him. He appointed a man as their commander and instructed them to obey their commander. One day, they angered him, so he ordered them to gather firewood. They said, “We hear and obey,” and gathered the firewood. He then ordered them to set it alight. They said, “We hear and obey,” and lit the fire. He said, “Throw yourselves into it.” The men hesitated, for the Prophet, peace and blessings be upon him, had commanded them to obey him. But why had they believed? They had believed out of fear of the Fire. So some of them said to others, “How can we throw ourselves into the Fire when we embraced faith only to flee from it?” This was sound reasoning. Thus, they refused to throw themselves into the fire.
When they returned to Medina and informed the Prophet, peace and blessings be upon him, of what had happened, he said: “Had they entered it, they would never have come out of it” (1), for they would have killed themselves. Whoever kills himself with fire will be punished with it in the Fire of Hell, for whoever kills himself by any means will be punished by it in the Fire of Hell (2). If he kills himself with a dagger, then on the Day of Resurrection he will be punished with that dagger in the Fire of Hell. If he kills himself by throwing himself down from a height, then a height will be created for him in the Fire, from which he will throw himself down and be punished thereby in the Fire of Hell. Whoever kills himself with poison, by drinking that poison, will be punished with it in the Fire of Hell. Had they entered the fire, they would have been punished with it in the Fire of Hell.