
69 Cal.2d 486 (1968)
In re HENDERSON HARRIS on Habeas Corpus.
Crim. No. 12308. 
Supreme Court of California. In Bank.  
Oct. 30, 1968.
 Jane R. Brady for Petitioner.
 John D. Maharg, County Counsel, and Jean Louise Webster, Deputy County Counsel, for Respondent.
 Agnew, Miller, Carlson & Powers and Maynard J. Klein for Real Party in Interest.
 TRAYNOR, C. J.
 Petitioner is in the constructive custody of bail under a civil arrest order of the Los Angeles County Superior Court. He questions the constitutionality of the statutes that authorize arrest and imprisonment on an ex parte application of the plaintiff in a civil action. (Code Civ. Proc.,  478-504.) The statutes do not require that the defendant be brought into court after his arrest or that he be notified that he has the right to release on bail (Code Civ. Proc.,  486), the right to apply for reduction of bail (Code Civ. Proc.,  503), the right to appear in court to challenge the legality of the arrest (Code Civ. Proc.,  503), and the right to appear by counsel (Cooke v. United States (1925) 267 U.S. 517, 537 [69 L.Ed. 767, 774, 45 S.Ct. 390]; Steen v. Board of Civil Service Comrs. (1945) 26 Cal.2d 716, 727 [160 P.2d 816]) and to seek appointment of counsel if he is indigent.  [fn. 1]
 Petitioner contends that this statutory procedure does not meet the standards of due process of law. [1] Habeas corpus *488 lies to test the constitutionality of the legislation under which the petitioner was imprisoned and is now constructively restrained on bail. (In re Petersen (1958) 51 Cal.2d 177, 181 [331 P.2d 24, 77 A.L.R.2d 1291].)
 Petitioner agreed to buy a truck tractor from Motor Truck Distributors Co. for $16,591.30, payable in monthly installments. He defaulted in his payments. Motor Truck Distributors Co. brought an action against him for recovery of the truck or $16,000 damages and invoked the remedy of claim and delivery. (Code Civ. Proc.,  509-521.) The sheriff could not find petitioner or the truck and returned the complaint and claim and delivery process unserved.
 The company then invoked the remedy of mesne civil arrest and bail under the statutes here attacked. (Code Civ. Proc.,  478-504.) The procedures followed by the company, the court, and the sheriff complied with those statutes. The company presented declarations to the superior court under penalty of perjury showing "that a sufficient cause of action exists, and that the case is one of those mentioned in Section 479."  [fn. 2] (Code Civ. Proc.,  481.) The company filed an undertaking, as required by section 482, to "pay all costs which may be adjudged to the defendant, and all damages which he may sustain by reason of the arrest, if the same be wrongful, or without sufficient cause. [2] The court ordered the sheriff to arrest petitioner and fixed bail at $16,000 plus a $4,000 penalty assessment.  [fn. 3]*489"
 The sheriff arrested petitioner on March 5, 1968, when he appeared at a sheriff's substation to report that the truck had been stolen from him. He was allowed to telephone his employer and an attorney. (Pen. Code,  815.5.) A sheriff's officer complied with the provision in Code of Civil Procedure section 484 that the officer who arrests the defendant "must deliver to him a copy of the affidavit [that resulted in issuance of the arrest order], and also, if desired, a copy of the order of arrest."  [fn. 4] About March 6, 1968, a sheriff's officer served petitioner with a summons and a complaint in the company's action. About March 8 an attorney referred by petitioner's employer visited him in jail. This attorney filed an answer to the complaint but refused to take any action to obtain petitioner's release from jail unless petitioner paid him $500.petitioner was unable to pay this fee.
 Petitioner spent five weeks in jail with no opportunity to appear in the superior court to seek release from his detention. He wrote to the Better Business Bureau stating that his custodians had told him he would be held until the company obtained a date for his court appearance or arranged for his release, "which could be forever." The bureau forwarded his letter to the Los Angeles County Public Defender. A deputy public defender interviewed petitioner, determined that he was indigent, and moved in the civil action for reduction of bail. On April 11, 1968, the superior court reduced bail to $1,000 plus a $250 penalty assessment.  [fn. 5]petitioner obtained a surety bond in this amount and has since been in the constructive custody of bail.
 [3a] A state cannot deprive a person of his life, liberty, or *490 property without affording him an opportunity to be heard by a tribunal empowered to decide the lawfulness of the deprivation. (Armstrong v. Manzo (1965) 380 U.S. 545, 550, 552 [14 L.Ed.2d 62, 65, 66-67, 85 S.Ct. 1187]; Endler v. Schutzbank (1968) 68 Cal.2d 162, 168, 180 [65 Cal.Rptr. 297, 436 P.2d 297].) Under the statutory scheme for mesne civil arrest the state deprives the defendant of his liberty through the process of its trial courts executed by its law enforcement officers. Although the statutory machinery is set in motion by a private plaintiff to satisfy a civil claim, the deprivation of liberty is effected by the state. (See Peterson v. Greenville (1963) 373 U.S. 244, 247-248 [10 L.Ed.2d 323, 325-326, 83 S.Ct. 1119]; Shelley v. Kraemer (1948) 334 U.S. 1, 13-14 [92 L.Ed. 1161, 1180-1181, 68 S.Ct. 836, 3 A.L.R.2d 441].) The due process of law required by the Fourteenth Amendment to the United States Constitution and article I, section 13, of the California Constitution is not afforded merely because the civil defendant may be able to get a hearing as to the lawfulness of his imprisonment by chance or by grace. [4a] The statute authorizing the deprivation must explicitly provide a fair opportunity for the defendant to be heard on that issue. (Coe v. Armour Fertilizer Works (1915) 237 U.S. 413, 424-425 [59 L.Ed. 1027, 1031-1032, 35 S.Ct. 625]; People v. Broad (1932) 216 Cal. 1, 7 [12 P.2d 941].) The provision that the arrested defendant may apply to the court at any time before trial or judgment to vacate the arrest order or to reduce bail (Code Civ. Proc.,  503) does not afford him a fair opportunity to challenge his imprisonment, for the Legislature has not required that he be given notice of his right to make the application. (See In re Lambert (1901) 134 Cal. 626, 629 [66 P. 851, 86 Am.St.Rep. 296, 55 L.R.A. 856].)
 Moreover, "The right to be heard would be, in many cases, of little avail if it did not comprehend the right to be heard by counsel." (Powell v. Alabama (1932) 287 U.S. 45, 68 [77 L.Ed. 158, 170, 53 S.Ct. 55, 84 A.L.R. 527]; Gideon v. Wainwright (1963) 372 U.S. 335, 344 [9 L.Ed.2d 799, 805, 83 S.Ct. 792, 93 A.L.R.2d 733]; Specht v. Patterson (1967) 386 U.S. 605, 608-609 [18 L.Ed.2d 326, 329-330, 87 S.Ct. 1209]; In re Gault (1967) 387 U.S. 1, 36 [18 L.Ed.2d 527, 551, 87 S.Ct. 1428].) The civil defendant cannot be expected to understand and to present the legal objections that may be raised in testing the validity of the arrest order. (See Murray v. Superior Court (1955) 44 Cal.2d 611, 618-619 [284 P.2d 1]; Ex parte Fukumoto (1898) 120 Cal. 316, 319-320 [52 P. 726]; Pousson *491 v. Superior Court (1958) 165 Cal.App.2d 750, 753-754 [332 P.2d 766].) An indigent defendant imprisoned under the process of mesne civil arrest is confined in the same jail as the indigent felon undergoing trial who is entitled to appointed counsel under Gideon and the indigent misdemeanant who is serving a sentence imposed only after a trial at which he was entitled to appointed counsel under California's constitutional standards. (In re Smiley (1967) 66 Cal.2d 606, 614-615 [58 Cal.Rptr. 579, 427 P.2d 179]; In re Johnson (1965) 62 Cal.2d 325, 329 [42 Cal.Rptr. 228, 398 P.2d 420.) [3b] A defendant who is deprived of his liberty by civil process is as much entitled to due process of law as a defendant who is deprived of his liberty because he is charged with crime.
 [4b] The mesne process of civil arrest without opportunity to be heard with the assistance of counsel is not due process.
 The writ is granted and petitioner is discharged from the constructive custody of bail. His surety will stand exonerated when this decision becomes final.
 McComb, J., Peters, J., Tobriner, J., Mosk, J., Burke, J., and Sullivan, J., concurred.
 By chance the facts as to petitioner's imprisonment came to the attention of the public defender, who obtained a hearing on a motion to reduce bail and petitioner's release on reduced bail.
 The declarations submitted by the company include an averment by a repossession agent that in October 1967 petitioner "advised me that he could not and would not make any further payments on the truck. He further stated that he had no intention of giving up the truck, but rather that he would keep it out of my reach and the reach of plaintiff Motor Truck Distributors Co." The agent set forth his many unsuccessful attempts to find the truck.
 The bail furnished by a civil defendant, however, is not "for an offense to which this section [Penal Code section 13521] applies." The sureties who furnish bail for the civil defendant bind themselves that he will be amenable to the civil court's process "during the pendency of the action, and to such as may be issued to enforce the judgment therein, or that they will pay to the plaintiff the amount of any judgment which may be recovered in the action." (Code Civ. Proc.,  487.) Thus the bail is designed to assure the civil defendant's appearance and the satisfaction of any judgment for the plaintiff, not to fine or penalize the defendant. The court's requirement of a penalty assessment was therefore unauthorized. (See 35 Ops. Cal.Atty.Gen. 77, 81-82 (1960).)
NOTES
[fn. 1]  1. Government Code section 27706, subdivision (c), provides that upon request the public defender "shall defend any person who is not financially able to employ counsel in any civil litigation in which, in the judgment of the public defender, the person is being persecuted or unjustly harassed."
[fn. 2]  2. Code of Civil Procedure section 479 sets forth five "cases," defined in part by the nature of the action and in part by the conduct of the defendant, when the remedy of civil arrest is available. Among these cases is "an action to recover the possession of personal property unjustly detained, when the property or any part thereof, has been concealed, removed, or disposed of, to prevent its being found or taken by the Sheriff."
[fn. 3]  3. Penal Code section 13521 provides for the levy of a penalty assessment of $5 for each $20 of "every fine, penalty, and forfeiture imposed and collected by the courts for criminal offenses" other than violations of the Vehicle Code, traffic ordinances, and the Fish and Game Code. "When any deposit of bail is made for an offense to which this action applies, the person making such deposit shall also deposit a sufficient amount to include the assessment. ..." If the bail is forfeited the assessment goes to the state Peace Officers' Training Fund. Section 13521 is constitutional as applied to bail in a criminal case. (People v. Norman (1967) 252 Cal.App.2d 381, 398-399 [60 Cal.Rptr. 609].)
[fn. 4]  4. Section 484 is the only provision in the statutory civil arrest scheme (Code Civ. Proc.,  478-504) requiring the furnishing of any information to the defendant concerning his arrest.
[fn. 5]  5. As to the impropriety of the penalty assessment in this civil action see fn. 3, supra.
