Petitioner, Robert Allen Jones, was committed to the California Rehabilitation Facility for treatment as a narcotic addict. In this habeas corpus proceeding, filed in propria persona, he attacks that commitment for failure to comply with the statutory procedural safeguards set forth in section 6451 of the Penal Code.1 There is merit to this contention.
In January of 1963, petitioner was charged with three counts of forgery. He pleaded not guilty and not guilty by reason of insanity. The court appointed two alienists to examine him. They reported that he was legally sane. This *327answered the only question submitted to them. On March 21, 1963, petitioner, now represented by the public defender, withdrew his prior pleas and pleaded guilty to one count of forgery. The court dismissed the other counts and continued the matter until April 11th for report and sentencing. On that date the court committed petitioner to the California Medical Facility at Vacaville as a narcotic addict, under Penal Code sections 6400 et seq. It is conceded that this commitment was invalid.
The following day, April 12th, the court set aside its commitment order of the 11th. It then held a “narcotic hearing” at which petitioner was not personally present. Counsel stipulated that the letter reports of the alienists who had previously examined petitioner could be admitted into evidence to show petitioner’s “propensities as far as addiction to dangerous drugs or narcotics is concerned.” After directing the sheriff to file a petition pursuant to Penal Code section 6451, the court continued the matter until April 26,1963.2
On April 26th the matter was submitted after counsel again stipulated that the alienists’ reports could be admitted into evidence. The court, without further proceedings, committed petitioner to the California Rehabilitation Facility as a person addicted to narcotics or in danger of becoming addicted by reason of repeated use of narcotics. Such procedure did not substantially comply with the requirements of the pertinent statutory provisions.
The civil commitment proceeding brought pursuant to Penal Code sections 6450 or 6451 is separate and distinct from any pending penal proceeding. The manner in which the civil commitment is commenced is set forth in section 5353 of the Welfare and Institutions Code. Unless the mandatory provisions of this section are substantially complied with, the commitment is fatally defective. The section provides:
“The person charged shall be taken before a judge of the superior court, to whom the affidavit and warrant of apprehension shall be delivered to be filed with the clerk. The judge shall then inform him of his rights to make a defense *328to such charge and to produce witnesses in relation thereto. The judge shall by order fix such time and place for the hearing and examination in open court as will give a reasonable opportunity for the production and examination of witnesses. Such order shall be entered at length in the minute book of the court or shall be signed by the judge and filed and a certified copy thereof shall be served on the person. The judge may order that such notice of the apprehension of the person and the hearing of the charge be served on such relatives of the person known to be residing in the county as the court deems necessary or proper. ’ ’
The order fixing the time and place for hearing must also state the purpose of the hearing, that is, to determine whether the person charged is addicted to narcotics or in imminent danger thereof. Additionally, proof of service on the person charged must appear of record.
Welfare and Institutions Code sections 5053, 5054 and 5055 state other procedural rights of the person charged.3 These sections provide, among other things, that the person charged has the right to subpoena witnesses, the right to be present at the hearing, the right to be represented by counsel, and if indigent the right to have court-appointed counsel. These sections further provide that the court must appoint two medical doctors who must examine the person charged, file a certificate with respect to the person’s condition, and attend the hearings.
With these provisions in mind we turn to the instant action. The proceedings on April 11th and 12th were clearly illegal.4 The proceedings on April 26th were also fatally defective, since the court did not comply with the statutory provisions. The record is devoid of any evidence that petitioner was arraigned or that petitioner was served with notice of the time and place of hearing. The record shows that no doctors attended the hearing and that the doctors who examined petitioner for sanity did not certify that petitioner was addicted or in imminent danger of becoming addicted to *329narcotics.5 The commitment, not being in compliance with the statutory requirements, must, therefore, be set aside. (See In re Raner, 59 Cal.2d 635 [30 Cal.Rptr. 814, 381 P.2d 638].)
The Attorney General urges, however, that the commitment was valid because petitioner’s counsel submitted the matter on April 26th after stipulating that the letter reports of the alienists could be admitted into evidence. This position is unsound.
The assistant public defender stated at the April 26th hearing “This matter is ready, Tour Honor. I think on the last court hearing [April 12th] the reports of Drs. Rogers and Port were stipulated into evidence in this matter. If not, we would stipulate them in at this time and would submit the matters.” Since the stipulation on its face admits of no broader interpretation than that certain documents could be admitted into evidence, the court can sustain the position of the Attorney General only if it holds that petitioner validly waived the rights provided for in Welfare and Institutions Code sections 5353, 5053, 5054 and 5055. If it be assumed that a person named in a petition filed pursuant to Penal Code section 6451 can waive the committing procedures required therein,6 the question then is whether the acts of petitioner or his counsel were sufficient to waive the hearing procedures so as to submit voluntarily to the commitment.
Certainly, petitioner, personally, did not expressly waive the commitment procedures. Nor did he impliedly waive his rights by failing to demand them at the April 26th hearing. Prom the record before us it appears that petitioner was brought before the court without arraignment or notice. The proceeding was summary, consisting of counsel’s stipulation and the pronouncement of judgment. Under these circumstances it is unrealistic to require petitioner, a person untrained in the law, to demand rights of which the trial court *330apparently was unaware. Therefore, the acts of petitioner did not constitute a waiver of the committing procedures.
Nor did the conduct of petitioner’s counsel constitute a waiver of such procedures. Here counsel made no defense. His only act, the stipulation, was apparently aimed at satisfying supposed jurisdictional requirements for commitment. If this conduct was waiver, it was total, tantamount to a plea of “guilty.” Counsel cannot, either expressly or impliedly, make such a plea without the concurrence of his client. Public policy, announced by the Legislature, supports this conclusion.
Penal Code section 6507 provides that “Hearing [for narcotic commitment] may be waived by consent of the person sought to be committed, expressed in open court.” This section is part of a complete commitment procedure contained in article 3, chapter 11, title 7 of part 3 of the Penal Code. Article 3 deals with alleged addicts who are not charged with crimes. Section 6507 does not apply directly to petitioner, who was committed under the preceding article, article 2, which relates to alleged addicts who are additionally charged with crimes. The article 2 commitment procedure is specified in the Welfare and Institutions Code. Although the specified provisions of that code contain no reference to the manner in which a person charged could voluntarily submit to commitment, the policy respecting waiver should be the same under either article.
The facts of this case demonstrate the wisdom of requiring a personal waiver when the waiver is equivalent to voluntary submission to commitment. At the April 11th proceeding petitioner and his counsel informed the court that petitioner was opposed to civil commitment even though the alternative was penal incarceration. Petitioner contends that he thereafter remained steadfast in opposition to commitment. The record does not refute his claim. It would be unreasonable to hold that counsel could subject petitioner to “voluntary” commitment against petitioner’s expressed desires. Such, however, would be the result, unless voluntary commitment under article 2 is valid only where the person charged has personally waived the commitment procedure.7
The writ of habeas corpus is granted. However, since penal *331proceedings against petitioner are still pending before the Superior Court of Alameda County, petitioner is not entitled to discharge from custody but is remanded to that court for further proceedings in connection with the matters there pending, and in accordance with the views herein expressed.8
Gibson, C. J., Traynor, J., Schauer, J., McComb, J., Tobriner, J., and Peek, J., concurred.
Penal Code section 6451 as it applied at the time of petitioner’s commitment provided in part: “Upon conviction of a defendant for any crime in any superior court, if the judge ascertains that the defendant is addicted or by reason of repeated use of narcotics is in imminent danger of becoming addicted to narcotics he shall adjourn the proceedings or suspend the imposition of the sentence and direct the sheriff to file a petition to ascertain if such person is addicted to narcotics or in imminent danger thereof unless in the opinion of the judge the defendant’s record and probation report indicate such a pattern of criminality that he does not constitute a fit subject for commitment under this section. If a petition is ordered filed, proceedings shall be conducted in substantial compliance with sections 5353, 5053, 5054, and 5055 of the Welfare and Institutions Code.’’
The petition is erroneously phrased in terms of a prior conviction, the sentence of which petitioner completely served. It is clear that where sentence has been imposed and served, a prior conviction will not support a section 6451 commitment. However, this error is technical since petitioner did at the time of his commitment stand convicted of a crime subsequent to the one specified, for which sentence had not been imposed.
The Legislature could not have intended literal compliance with all of the provisions of sections 5053, 5054 or 5055 of the Welfare and Institutions Code. These sections were enacted to provide a hearing procedure for mentally irresponsible persons. For that reason, if taken literally, they would be, in part, inappropriate for a civil narcotic commitment procedure.
The April 11th proceeding is eoneededly invalid. The April 12th proceeding is invalid since petitioner was not present. (Welf. & Inst. Code, § 5054.)
The letters from these doctors indicate that petitioner told each alienist of some drug involvement. One alienist suggested the narcotic treatment program. The other made no statement in this regard.
The Legislature did not expressly state whether the committing procedure required by Penal Code section 6451 may be dispensed with if the person charged chooses to acquiesce to commitment. It is clear, however, that the Legislature does not consider narcotic addicts incompetent to voluntarily submit to treatment. For example, persons charged as narcotic addicts but not convicted of crimes may waive the commitment hearings. (Pen. Code, § 6507.) Since voluntary submission to commitment conserves the time and effort of the parties and the judiciary, such waiver, if properly made, should be facilitated.
The Legislature has provided the procedural framework in which the person sought to be committed may vigorously contest the commitment. It is therefore incumbent upon counsel for an alleged addict to view the procedure as adversary in nature unless the alleged addict indicates his *331desire to the contrary. Any other approach might support a finding of lack of effective aid of counsel. (See People v. Ibarra, 60 Cal.2d 460 [34 Cal.Rptr. 863, 386 P.2d 487].)
On remand the court must again exercise its discretion in making the preliminary determination as to whether petitioner may be addicted to narcotics or in imminent danger thereof. That determination, and any proceedings which follow, should be conducted in accordance with the law as it now exists rather than the law as it existed at the time of the commitment here invalidated. (See People v. Ortiz, ante, p. 249 [37 Cal.Rptr. 891, 391 P.2d 163].)