The privilege of the use of this writ was regarded as a foundation of human freedom and the British citizen insisted upon this privilege wherever he went whether for business or colonisation. This is how it found a place in the Constitution of the United States when the British colonies in America won their independence and established a new State under that Constitution.
In India, under the Constitution, the power to issue a writ of habeas-corpus is vested only in the Supreme Court and the High Courts. The writ is a direction of the Court to a person who is detaining another, commanding him to bring the body of the person in his custody at a specified time to a specified place for a specified purpose.
A writ of habeas-corpus has only one purpose: To set at liberty a person who is confined without legal justification: to secure release from confinement of a person unlawfully detained. The writ does not punish the wrongdoer. If the detention is proved unlawful, the person who secures liberty through the writ may proceed against the wrongdoer in any appropriate manner. The writ is issued not only against authorities of the State but also to private individuals or organizations if necessary.