The Doctrine of Necessity is the basis on which extra-legal actions by state actors, which are designed to restore order, are found to be constitutional. The maxim on which the doctrine is based originated in the writings of the medieval jurist Henry de Bracton, and similar justifications for this kind of extra-legal action have been advanced by more recent legal authorities, including William Blackstone.
In modern times, the doctrine was first used in a controversial 1954 judgment in which Pakistani Chief Justice Muhammad Munir validated the extra-constitutional use of emergency powers by Governor General, Ghulam Mohammad. In his judgment, the Chief Justice cited Bracton's maxim, 'that which is otherwise not lawful is made lawful by necessity', thereby providing the label that would come to be attached to the judgment and the doctrine that it was establishing.
The Doctrine of Necessity has since been applied in a number of Commonwealth countries, and in 2010 was invoked to justify extra-legal actions in Nigeria.
On October 24, 1954 the Governor-General of Pakistan, Ghulam Mohammad, dissolved the Constituent Assembly and appointed a new Council of Ministers on the grounds that the existing one no longer represented the people of Pakistan. Stanley de Smith argues that the real reason for the dissolution was because Mohammad objected to the constitution which the Assembly was about to adopt. The President of the Constituent Assembly, Maulvi Tamizuddin, appealed to the Chief Court of Sind at Karachi to restrain the new Council of Ministers from implementing the dissolution and to determine the validity of the appointment of the new Council under Section 223-A of the constitution.
In response, members of the new Council of Ministers appealed to the court saying that it had no jurisdiction to approve the request of the President to overturn the dissolution and appointments. They argued that Section 223-A of the constitution had never been validly enacted into the Constitution because it was never approved of by the Governor-General, and therefore anything submitted under it was invalid. The Chief Court of Sind ruled in favour of President Tamizuddin and held that the Governor-General's approval was not needed when the Constituent Assembly was acting only as a Constituent Assembly and not as the Federal Legislature. The Federation of Pakistan and the new Council of Ministers then appealed to the court, the appeal was heard in March 1955 (Federation of Pakistan v Maulvi Tamizuddin Khan).