Defendant appeals the judgment and sentence entered upon his conviction of operating while intoxicated (OWI), first offense, in violation of Iowa Code section 321J.2 (1995). He argues his guilty plea was invalid because he was not informed that as a consequence of pleading guilty, his driver’s license could be revoked for six years and his vehicle impounded. Defendant further asserts his counsel was ineffective for failing to inform him of these consequences. We affirm in part and vacate in part.
I. Background Facts and Proceedings.
Defendant filed a written guilty plea to OWI, first offense. The written plea provided that the maximum penalty for the offense of OWI is one year in jail and/or a $1500 fine plus surcharge. Following a hearing the district court accepted defendant’s plea finding it was both knowing and voluntary.
Defendant was sentenced to a one-year jail term, all but two days suspended, fined $500 plus a surcharge, taxed court costs, and ordered to pay $60 in restitution. In addition, the district court found that this was defendant’s third lifetime conviction and revoked his driver’s license for a period of six years pursuant to Iowa Code section 321J.4(3)(a). It further ordered that defendant’s vehicle be impounded pursuant to Iowa Code section 321J.4B (Supp.1995).
On appeal defendant argues his guilty plea was not knowingly and voluntarily entered because he was not informed his punishment could include a six-year license revocation and impoundment of his vehicle. Defendant maintains the court was required to inform him of these consequences pursuant to Iowa Rule of Criminal Procedure 8(2)(b)(2) (“The mandatory minimum punishment, if any, and the maximum possible punishment provided by the statute defining the offense to which the plea is offered.”). Defendant further contends his counsel was ineffective in failing to inform him that license revocation and impoundment were consequences of pleading guilty to OWI.
II. Direct and Collateral Consequences.
To the extent defendant alleges the sentencing court failed to inform him fully of the consequences of his plea, he implicates the due process clause of the Fourteenth Amendment to the United States Constitution. See Saadiq v. State, 387 N.W.2d 315, 324 (Iowa 1986). To adhere to the requirements of the Fourteenth Amendment a sentencing court must insure the defendant understands the direct consequences of the plea including the possible maximum sentence, as well as any mandatory minimum punishment. Id. at 324-25. However, the court is not required to inform the defendant of all indirect and collateral consequences of a guilty plea. Id. at 325.
We have explained that:
The distinction between “direct” and “collateral” consequences of a plea, while sometimes shaded in the relevant decisions, turns on whether the result represents a definite, immediate and largely automatic effect on the range of defendant’s punishment.
State v. Warner, 229 N.W.2d 776, 782 (Iowa 1975) (quoting Cuthrell v. Director, Patuxent Institution, 475 F.2d 1364, 1366 (4th Cir.1973)). In the following cases we found that certain consequences of a guilty plea were collateral, and thus the district court had no duty to inform defendant of them: Kinners*909ley v. State, 494 N.W.2d 698, 700 (Iowa 1993) (limitation on parole eligibility); Mott v. State, 407 N.W.2d 681, 683 (Iowa 1987) (deportation); Saadiq, 387 N.W.2d at 325 (prohibition from carrying a firearm upon conviction of third-degree theft); State v. Woolsey, 240 N.W.2d 651, 653-54 (Iowa 1976) (ineligibility for deferred judgment or suspended sentence and probation due to prior convictions); Warner, 229 N.W.2d at 782 (penal consequences of companion charge or effect of instant charge on the strength of prosecution’s proof in companion case); and State v. Christensen, 201 N.W.2d 457, 459 (Iowa 1972) (effect of conviction upon future convictions).
A. License revocation.
Defendant’s license was revoked pursuant to Iowa Code section 321J.4(3)(a) which provides:
Upon a plea or verdict of guilty of a third or subsequent violation of section 321J.2, the court shall order the department to revoke the defendant’s motor vehicle license or nonresident operating privilege for a period of six years....
The result of revocation upon pleading guilty to OWI (where the defendant has two or more prior lifetime violations of section 321J.2) may be definite, immediate, and largely automatic. However, we do not believe it has an effect on the “range of defendant’s punishment,” and therefore conclude it is not a direct consequence of a guilty plea.
While license revocation may carry the sting of punishment, we have explained that the “purpose of the license revocation provision in section 321J.4 is ‘to protect the public by providing that drivers who have demonstrated a pattern of driving while intoxicated be removed from the highways.’ ” See State v. Moore, 569 N.W.2d 130, 132 (Iowa 1997) (quoting State v. Blood, 360 N.W.2d 820, 822 (Iowa 1985)). We have also concluded license revocation is not punishment for purposes of the double jeopardy clause. State v. Krebs, 562 N.W.2d 423, 424-25 (Iowa 1997).
Other jurisdictions have similarly determined that license revocation is a collateral rather than direct consequence of a guilty plea. Moore v. Hinton, 513 F.2d 781, 782-83 (5th Cir.1975) (license suspension imposed following plea of guilty to OWI was not punishment but collateral consequence of conviction); Villa v. State, 456 A.2d 1229, 1231 (Del.1983) (license revocation is not a criminal penalty or punishment); Stoltz v. State, 657 N.E.2d 188, 192 (Ind.Ct.App.1995) (even though suspension of license was automatic upon plea of guilty to operating while intoxicated, it was a collateral consequence); Commonwealth v. Duffey, 536 Pa. 436, 639 A.2d 1174, 1176 (Pa.1994) (license revocation was collateral consequence to pleading guilty to underage drinking); State v. Madison, 120 Wis.2d 150, 353 N.W.2d 835, 841 (Wis.Ct.App.1984) (no due process right to be informed of collateral consequence of license revocation upon pleading guilty to underlying offense).
Because we find license revocation is a collateral and not a direct consequence of a guilty plea, the district court had no duty to inform the defendant of it. We conclude the defendant’s plea was knowingly and voluntarily entered. See Saadiq, 387 N.W.2d at 325.
B. Impoundment.
Defendant similarly contends that the court was required to inform him of the consequence of impoundment in order for his plea to be knowing and voluntary. The State notes that an order of impoundment may not have been proper in this case and that it is unclear whether impoundment occurred because defendant transferred ownership of his vehicle prior to the entry of the order.
The impoundment was ordered pursuant to Iowa Code section 321J.4B which provides:
[i]f a person is convicted of a second, third, or subsequent offense of operating while intoxicated, the court shall order that any motor vehicles owned by the person and used to commit the offense ... be impounded or immobilized....
In State v. Sharp, 572 N.W.2d 917, 918 (Iowa 1997), we held that impoundment is *910permitted pursuant to section 321J.4B only where a defendant is convicted of the enhanced offense of second, third or subsequent OWI. This section does “not apply with respect to two or more convictions of OWI, first offense.” Id. Defendant pleaded guilty to first offense OWI; therefore, the order of impoundment was entered in error.
When a court imposes a sentence which statutory law does not permit, the sentence is illegal, and such a sentence is void and we will vacate it. State v. Hess, 533 N.W.2d 525, 527 (Iowa 1995). We note that defendant does not contend the order of im-poundment was improper; however, “[w]e cannot permit a void sentence to stand even when a party does not raise the issue.” See Wilson v. Fenton, 312 N.W.2d 524, 529 (Iowa 1981). Because we find the order of im-poundment was improper, we need not address whether it was a direct or collateral consequence.
III. Ineffective Assistance.
Defendant next contends his trial counsel was ineffective for failing to advise him of the consequences of revocation and impoundment. “The general test applied to a claim of ineffective assistance of counsel is ‘whether under the entire record and totality of the circumstances counsel’s performance was within the range of normal competency.’ ” Mott, 407 N.W.2d at 582 (quoting Snethen v. State, 308 N.W.2d 11, 14 (Iowa 1981)). The defendant must show (1) counsel failed to perform an essential duty, and (2) prejudice resulted. Id. To show counsel was ineffective in a guilty plea case, the defendant “must show that counsel’s advice was not within the normal range of competency demanded of attorneys in criminal cases.” Id.
“When the ineffectiveness claim is based on alleged failure to advise a defendant of the consequences of a guilty plea, the rule is that, if the consequences flow ‘directly’ from the plea, the plea may be held invalid.” Id. On the other hand, if “the fallout from the plea is ‘collateral,’ counsel is generally not held to be ineffective for failing to inform the defendant about it.” Id. at 582-83.
Having concluded that the consequence of license revocation is collateral, we find counsel was not ineffective in failing to inform defendant of it. The failure to advise a defendant concerning a collateral consequence, even serious ones, cannot provide a basis for a claim of ineffective assistance of counsel. Id. at 583.
IV. Conclusion.
Defendant’s guilty plea to the offense of operating while intoxicated was not involuntary or unknowing because of the court’s failure to inform him of the collateral consequence of license revocation. Further, counsel was not ineffective for failing to advise defendant of this collateral consequence. We vacate the order of impoundment.
AFFIRMED IN PART; VACATED IN PART'
All justices concur except SNELL, J., and LAVO RATO, J., who dissent.