(A) On filing, the clerk of the court must immediately deliver the petition to the presiding judge or his or her designee. The Writ of Habeas Corpus protects prison inmates from false imprisonment to ensure people are not thrown into jail unlawfully.How Do I Fill Out the Form? There is an official form (Judicial Council Form HC-001) for filing a state petition for writ of habeas corpus. Generally speaking, the writ of habeas corpus is available in any case where the trial court has acted in excess of its jurisdiction. A Writ of Habeas Corpus is used to appeal a court decision or to challenge conditions of probation or parole. A writ of habeas corpus is a petition that an individual uses to challenge their conviction or sentence in California. Habeas petitions provide prisoners whose rights are being violated with a means of requesting assistance from a judge. Generally speaking, the writ of habeas corpus is available in any case where the trial court has acted in excess of its jurisdiction. This petition, called a writ of Habeas Corpus, is filed in Federal Court (US District Court ) whether you are serving time in a federal or state prison.