
735 So.2d 482 (1999)
STATE of Florida, Petitioner,
v.
William THOMPSON, Respondent.
No. 92,254.
Supreme Court of Florida.
May 20, 1999.
*483 Robert A. Butterworth, Attorney General, Robert J. Krauss, Senior Assistant Attorney General, Chief of Criminal Law, and Ronald Napolitano, Assistant Attorney General, Tampa, Florida, for Petitioner.
James Marion Moorman, Public Defender, and Deborah K. Brueckheimer, Assistant Public Defender, Tenth Judicial Circuit, Bartow, Florida, for Respondent.
SHAW, J.
We have for review Thompson v. State, 706 So.2d 1361 (Fla. 2d DCA 1998), wherein the district court acknowledged conflict with Williams v. State, 691 So.2d 484 (Fla. 4th DCA 1997). We have jurisdiction. Art. V, § 3(b)(4), Fla. Const. We quash Thompson.
Based on an incident that took place February 22, 1995, Thompson was charged with escape, obstructing an officer with violence, having no valid driver's license, and alteration of license plates. After the State announced at a preliminary hearing that it would be seeking enhanced penalties under the habitual felony offender statute, Thompson pled nolo contendere to the charges. The following discussion then took place at the hearing:
Q [The court]. Do you understand the representations made by Ms. Swanick that you will enter a plea of no contest to one count of escape from police custody, a second degree felony which carries a maximum sentence of 15 years Florida State Prison as a regular sentence or 30 years Florida State Prison as a habitual felony offender?
A [Thompson]. Yes, ma'am.
Q. In addition you are charged with one count of obstructing or opposing an officer with violence, charged as a third degree felony carrying a 5 or 10 year Florida State Prison sentence.
A. Yes, ma'am.
Q. There are two misdemeanor charges, a no valid driver's license and alteration of the license plate. Do you understand that?
A. Yes, ma'am.
The court sentenced Thompson as an habitual offender based on his extensive record, and Thompson appealed.
Thompson claimed on appeal that his plea was involuntary because the second requirement under Ashley v. State, 614 So.2d 486 (Fla.1993), had not been fulfilled. The district court ruled that although Thompson had been given notice of intent to seek habitualization, had been informed of his eligibility for habitualization, and had been told the maximum habitual offender terms for his felony offenses, he had not been told that habitualization could affect the possibility of early release. The district court reversed, ordered that Thompson be given an opportunity to withdraw his plea, and acknowledged conflict with Williams v. State, 691 So.2d 484 (Fla. 4th DCA 1997), wherein the district court held that an Ashley violation cannot be raised for the first time on direct appeal.
The State now argues that a violation of the second Ashley requirement cannot be raised on direct appeal unless the defendant first files a timely motion to withdraw the plea in the trial court. We agree.
*484 This Court in Ashley v. State, 614 So.2d 486 (Fla.1993), ruled that in order for a defendant to be habitualized following a plea of guilty or nolo contendere, two separate requirements must be met:
In sum, we hold that in order for a defendant to be habitualized following a guilty or nolo plea, the following must take place prior to acceptance of the plea: 1) The defendant must be given written notice of intent to habitualize, and 2) the court must confirm that the defendant is personally aware of the possibility and reasonable consequences of habitualization.
Id. at 490 (footnote omitted). The Court explained what it meant by "reasonable consequences":
The defendant should be told of his or her eligibility for habitualization, the maximum habitual offender term for the charged offense, the fact that habitualization may affect the possibility of early release through certain programs, and, where habitual violent felony offender provisions are implicated, the mandatory minimum term. As noted in the rule, "[c]ounsel for the prosecution and the defense shall assist the trial judge in this function." Fla. R.Crim. P. 3.172(a).
Id. at 490 n. 8.[1]
The two Ashley requirements have different legal bases and are substantively different in nature. The first requirement, i.e., written notice, is based on due process concerns and is dictated by the plain language of the habitual offender statute, which provides in relevant part: 2.
Written notice shall be served on the defendant and the defendant's attorney a sufficient time prior to the entry of a plea or prior to the imposition of sentence in order to allow the preparation of a submission on behalf of the defendant.
§ 775.084(3)(a), Fla. Stat. (1995). Compliance with this provision is a purely legal matter discernable from the record and no contemporaneous objection is required to preserve this issue for review on direct appeal.[2]
The second requirement, on the other hand, i.e., informing the defendant of the reasonable consequences of habitualization, is based on voluntariness concerns and is dictated by this Court's case law and rules of procedure. The Court in Ashley explained:
[T]his Court has ruled that in order for a plea to be knowing and intelligent the defendant must understand the reasonable consequences of the plea, including the maximum penalty that may be imposed:
Second, a defendant must understand the nature of the charge and the consequences of his plea. The purpose of this requirement is to ensure that he knows what particular act he has committed, what law he has violated, and what maximum penalty may be imposed for the offense with which he is charged.
This ruling was memorialized two years later in rule 3.172, which now reads:
. . . .
(c) Determination of Voluntariness. Except when a defendant is not present for a plea ... the trial judge should, when determining voluntariness, place the defendant under oath and shall address the defendant personally and shall determine that he or she understands:
(1) the nature of the charge to which the plea is offered, the mandatory minimum penalty provided by law, if any, and the maximum possible penalty provided by law.

*485 . . .
Ashley, 614 So.2d at 488 (citations and emphasis omitted). The question of voluntariness is a matter for the trial court to determine based on all the evidence surrounding the plea, as explained below.
This Court in Robinson v. State, 373 So.2d 898 (Fla.1979), held that a voluntariness claim must be presented to the trial court in a motion to withdraw the plea:
[W]e find that an appeal from a guilty plea should never be a substitute for a motion to withdraw a plea. If the record raises issues concerning the voluntary or intelligent character of the plea, that issue should first be presented to the trial court in accordance with the law and standards pertaining to a motion to withdraw a plea. If the action of the trial court on such motion were adverse to the defendant, it would be subject to review on direct appeal. The standards for the withdrawal of a guilty plea both before and after sentence were discussed in detail in Williams v. State, 316 So.2d 267 (Fla.1975). After sentence is imposed, the burden is on the defendant to prove that a manifest injustice has occurred. Williams v. State; ABA Standards Relating to the Administration of Criminal Justice, Pleas of Guilty, 14-2.1 (1979). To adopt the view asserted by the appellant in this case would in effect eliminate both the necessity for a defendant to move for a withdrawal of his plea and the obligation to show a manifest injustice or prejudice as grounds for such a plea withdrawal after sentence.
Robinson, 373 So.2d at 902-03. The district court in Rhodes v. State, 704 So.2d 1080 (Fla. 1st DCA 1997), explained further:
[A] defendant who seeks to challenge the voluntariness of a plea on direct appeal must preserve the issue for review in the trial court by filing a timely motion to withdraw. Otherwise, there would be no record relating to the claim and there would be no ruling or decision to review in the appellate court.
Id. at 1082.[3]
Absent a timely motion to withdraw the plea, the issue of voluntariness may be raised in the trial court in a motion for postconviction relief if the issue has not been previously raised and ruled upon. Florida RCrP Rule 3.850 provides in relevant part:
A prisoner in custody under sentence of a court established by the laws of Florida claiming the right to be released on the ground that ... the plea was given involuntarily ... may move, in the court that entered the judgment or imposed the sentence, to vacate, set aside, or correct the judgment or sentence.
Fla. RCrP Rule 3.850(a). See also § 924.06(3), Fla. Stat. (1995) ("A defendant who pleads guilty or nolo contendere with no express reservation of the right to appeal shall have no right to a direct appeal. Such a defendant shall obtain review by means of collateral attack.").[4]
*486 Based on the foregoing, we hold that a violation of the first Ashley requirement (i.e., written notice of intent to seek habitualization) is a purely legal issue and may be raised for the first time on direct appeal. A violation of the second requirement, on the other hand, (i.e., informing the defendant of the reasonable consequences of habitualization) involves a fact-based determination regarding the voluntariness of the plea and must be raised in the trial court, either in a timely motion to withdraw the plea or in a motion for postconviction relief. An adverse ruling on either motion is reviewable on appeal.
We quash Thompson and approve Rhodes on this issue. We also approve the result in Williams.[5] We remand the present case for further proceedings consistent with this opinion and without prejudice to Thompson's right to raise this issue in the trial court via postconviction motion.[6]
It is so ordered.[7]
HARDING, C.J., ANSTEAD, J., and OVERTON and KOGAN, Senior Justices, concur.
WELLS, J., concurs in part and dissents in part with an opinion.
PARIENTE, J., concurs in result only.
WELLS, J., concurring in part and dissenting in part.
I concur in the result of this case. I concur that the Criminal Appeal Reform Act of 1996 does not apply to this case. I concur with the majority's discussion as to the second prong of Ashley v. State, 614 So.2d 486 (Fla.1993).
I disagree, however, with dismissing the first prong of Ashley because it is not the basis of the majority's decision in this case, and the discussion is dicta. I also disagree with footnote 5, which disapproves Surinach v. State, 676 So.2d 997 (Fla. 3d DCA 1996).
NOTES
[1]  The Court subsequently found that the second Ashley requirement had not been met in State v. Wilson, 658 So.2d 521 (Fla.1995), but did not decide whether the issue must be preserved at the trial level.
[2]  Ashley, 614 So.2d at 490 (holding that "preplea notice of habitualization is clearly a legal matter, involving no factual determination," and thus "no contemporaneous objection is required to preserve" this issue).
[3]  See also Fla. R.App. P. 9.140(b), which provides in relevant part:

(2) Pleas. A defendant may not appeal from a guilty or nolo contendere plea except as follows:
(A) A defendant who pleads guilty or nolo contendere may expressly reserve the right to appeal a prior dispositive order of the lower tribunal, identifying with particularity of the point of law being reserved.
(B) A defendant who pleads guilty or nolo contendere may otherwise directly appeal only
. . . .
(iii) an involuntary plea, if preserved by a motion to withdraw plea....
[4]  See also Robinson, 373 So.2d at 903 ("We recognize that the failure of a defendant to raise the issue of the validity of the plea by an appeal does not prohibit him from subsequently seeking collateral relief if the issues have not been previously addressed and ruled upon."); Rhodes, 704 So.2d at 1083 ("At this point, the validity of [the defendant's] plea can only be presented in a postconviction motion under rule 3.850."); Williams, 691 So.2d at 485 ("In the instant case, since Appellant has not expressly reserved the right to direct appeal, he may obtain review only by collateral attack.").
[5]  To the extent Surinach v. State, 676 So.2d 997 (Fla. 3d DCA 1996), is inconsistent with our present opinion, we disapprove Surinach.
[6]  We note that the present case precedes the effective date of the Criminal Appeal Reform Act of 1996. See ch. 96-248, § 9, at 957, Laws of Fla. ("This act shall take effect July 1, 1996.").
[7]  We decline to address the other issue raised by Thompson since it was not the basis for our review.
