Back Home 5 News 5 Unlawful detention and fitness to plead: the scope of habeas corpus

Unlawful detention and fitness to plead: the scope of habeas corpus

11 Jun 2024

| Author: Warren Brookbanks

Teika v District Court [2024] NZHC 1017


The rules governing unfitness to stand trial are prescriptive. The Criminal Procedure (Mentally Impaired Persons) Act 2003 (CPMIP) is a statutory code that must be applied according to its strict terms.

This suggests a measure of literalism when interpreting particular provisions in the Act, even where this may produce an outcome contrary to the expectations of the legislature.

This was the situation in Teika v District Court. The High Court granted a writ of habeas corpus after concluding that the applicant’s detention in prison as a person unfit to stand trial, where the legislation mandated either release on bail or detention in a psychiatric facility, was unlawful and contrary to provisions in the Bill of Rights Act 1990.

This note outlines the facts of Teika and the High Court’s reasoning in granting the writ of habeas corpus.


The facts

In Teika v District Court [2024] NZHC 1017 the issue was whether the defendant had been unlawfully detained when, after a finding of unfitness to stand trial, he was detained in custody, contrary to the express terms of s 23(2). The relevant parts of s 23 state:

  • When a person is found unfit to stand trial or is acquitted on account of his or her insanity, the court must order that inquiries be made to determine the most suitable method of dealing with the person under s 24 or s 25.
  • For the purposes of the inquiries under subsection (1),the court must either (a) make it a condition of a grant of bail that the person go to a place approved by the court for the purposes of the inquiries or (b) remand the person to a hospital or a secure facility.

The defendant faced five charges of unlawful sexual connection and one of obtaining by deception but was found unfit to stand trial.

An involvement hearing was scheduled to take place, but because Teika had breached bail he was remanded in custody before the involvement hearing took place. A further application for bail, after he had been found unfit to stand trial, was also rejected.

Teika then applied for a writ of habeas corpus on the grounds that he was being unlawfully detained in prison contrary to s 23(1) and (2).

The question of whether a person’s detention is lawful is the primary issue under s 14(1) of the Habeas Corpus Act 2001. Section 14(2) of the Act provides: A judge dealing with an application must enquire into the matters of fact and law claimed to justify the detention and is not confined in that enquiry to correction of jurisdictional errors.

The only limitation in s 14(2) is that the judge cannot call into question a person’s conviction for an offence or a ruling as to bail (ss 14(2)(a) and (b)).

The court referred to Manuel v Superintendent, Hawkes Bay Regional Prison [2005] 1 NZLR 161 (CA) where the Court of Appeal considered that while a court on a habeas corpus application is not confined to jurisdictional enquiry, Parliament must have contemplated that consideration of underlying questions of fact and law is possible only within the procedures provided in the Act (at [47]).

In Manuel, the Court of Appeal noted that while the production of relevant warrants would normally provide the legal justification for imprisonment or other statutory confinements, that is not always a decisive answer to a habeas corpus application.

The court said the determinative test for the availability of habeas corpus was whether the arguments were “properly susceptible to fair and summary determination”. If not, they should be held over for evaluation in judicial review proceedings.

In the present case, the court held that while an option was to defer the matter to be dealt with on appeal because there was scope to make enquiries into the underlying facts and law, if in the interests of justice, and there was no dispute as to factual matters, this was an appropriate case to determine if the applicant’s continued detention was lawful.


The District Court’s decision

In the District Court, the applicant argued that he should be released under one of the provisions in s 23(2). The judge acknowledged that Teika had been found unfit to stand trial, but because of risk factors “and a strong case of offending on bail”, he was not a suitable candidate for bail.

But because there was no available bed in a secure facility, the court had the stark choice of releasing Teika on bail or retaining him in custody.

The judge took the view that according to the scheme of the CPMIP, s 23 did not come into play immediately on a finding of unfitness, but only once the involvement hearing under s 10 of the CPMIP had been determined.

Section 13 of the CPMIP defined the outcomes once the defendant’s involvement had been considered. In particular, subs (4) determined that once the court was “satisfied” as to involvement, it was mandatory to deal with the defendant under subpart 3, which relates to the treatment, detention and care of offenders found unfit to stand trial or acquitted on account of insanity.

In the District Court judge’s view, s 13(4) was the “gateway” to s 23, meaning that only after there had been an involvement hearing determination could the court exercise the options of bail or remand to a hospital as required by s 23(2). Accordingly, he had jurisdiction to remand the defendant in custody since the jurisdiction under s 23(1) did not arise until an involvement finding had been given.


The applicant’s case

This interpretation was challenged by counsel for the applicant who argued that a plain reading of s 23 meant Teika could be discharged or dealt with only as a healthcare recipient and should be granted bail or remanded to a secure facility, since it would be unlawful to remand him in prison.

This problem arose because s 23 was not amended when the provisions of the CPMIP were amended in 2018 and the involvement hearing was re-sequenced to occur after a finding of unfitness. The applicant’s approach to s 23, which applies on a finding of unfitness to stand trial, was presented as the only sensible interpretation because once a finding of unfitness is made, that person can never be imprisoned, at least pending restoration of competency.

It was also argued that that interpretation was consistent with the New Zealand Bill of Rights Act 1990, in particular the right not to be subjected to “disproportionately severe treatment or punishment” (s 9) and the right to be “treated with humanity and respect for the inherent dignity of the person” (s 23(5).

Furthermore, because unfit defendants are entitled, as healthcare recipients, to be kept in a therapeutic environment rather than a prison, holding the applicant in prison while not criminally liable would result in disproportionately severe treatment and inconsistent with the rights to be treated with humanity and respect for the inherent dignity of the person.


The Crown’s argument

The Crown argued that the case was not suitable for the issue of a writ of habeas corpus. The warrant was valid and there was no error as to its issue.

In addition, s14 (2)(b) of the Habeas Corpus Act mandated that a judge on a habeas corpus application not call into question a ruling as to bail “by a court of competent jurisdiction”.

The Crown invited the court to hear the matter as a general appeal against the decision of the District Court.

Nevertheless, it agreed that the court should order the applicant’s remand in a secure hospital or facility under s 23(2)(b), regardless of whether a bed was available or not, since holding the applicant in custody “appears unlawful” (at [25]). The Crown’s view was that the District Court judge misinterpreted s 23, but the most appropriate way to interpret the section is that once a determination of unfitness is made, then s 23 is triggered, regardless of whether an involvement hearing has occurred.


The High Court decision

Dunningham J held that while the decision was amenable to appeal in the usual way, she was unwilling to decline to determine the issue under s 14(1A)(b) of the Habeas Corpus Act. Both parties agreed that s 23 is intended to apply as soon as a finding of unfitness is made, and that the applicant should not be remanded in custody since he was not at risk of being found criminally liable for the acts alleged.

Since this was a confined legal issue and not live when the warrant to detain was issued, there was some urgency in ensuring the applicant was held in the most appropriate institution, granted the finding that he was unfit to stand trial. Dunningham J said at [29]:

The issue turns on the interpretation of s 23. I accept that s 23 is in its current form because it was drafted to reflect the fact that, prior to 2018, a finding of unfitness was made after an involvement hearing. When the Act was amended in 2018, no clear thought seems to have been given to amending this section as well to deal with the situation once a finding of unfitness is made, but before inquiries as to disposition are able to be made. As currently worded, there is a tension between the section saying its provisions apply once a person is found unfit to stand trial, and the fact that the section anticipates that this is for the purpose of making inquiries as to disposition.”

The judge concluded she was satisfied that an individual found unfit to stand trial should not remain in prison, since that person is no longer at risk of being found criminally liable and it is not appropriate that he or she be held in custody.

It was consistent with the intent of the legislation and the NZBORA that the options outlined in s 23(2)(b) should apply at the point a person has been found unfit to stand trial, even though they appear to apply only once the court is in a position to make inquiries into disposition.

For these reasons, the court granted the application for a writ of habeas corpus and ordered that the applicant be remanded to a hospital or secure facility.



This is an unusual case in that habeas corpus is seldom argued in the context of unfitness to stand trial, where the authorisation for detention is invariably lawful, as one might expect.

The unexpected challenge to the lawfulness of the custodial detention in this case arose from the consequences of an overlooked statutory amendment and the pressure on resources to be able to provide an appropriate therapeutic disposition.

Both factors provided the conditions for a perfect storm, warranting habeas corpus intervention.

One has sympathy for the District Court judges who were caught between a rock and a hard place. The memory of the involvement hearing having been resolved before a determination of fitness was still fresh and created an understandable reticence to move to the subpart 3 process before an involvement hearing had actually taken place. On the other hand, the general principle is clear enough: that where mental health legislation is invoked to detain a person against his will, “a high degree of care must be exercised to see that the facts of the case are within the strict boundaries the Act defines.” (Mitchell v Allen [1969] NZLR 110, 113).

The applicant was quite within his rights to insist on the literal application of s 23(1) and (2) once it was determined that he was unfit to stand trial. Clearly, an amendment to the CPMIP is now required. This could be achieved quite simply by adding in s 23(1), after “unfit to stand trial,” the words “and a determination of involvement made”.


Warren Brookbanks is a Professor at AUT Law School and a member of The Law Association’s Mental Health and Disability Law committee.

Subscribe to


The weekly online publication is full of journalistic articles written for those in the legal profession. With interviews, thought pieces, case notes and analysis of current legal events, LawNews is a key source of news and insights for anyone working within or alongside the legal field.

Sign in or
become a Member
to join the discussion.


Submit a Comment

Your email address will not be published. Required fields are marked *

Latest Articles