
997 So.2d 1287 (2009)
Andre Odell GREGORY, Appellant,
v.
The STATE of Florida, Appellee.
No. 3D07-2155.
District Court of Appeal of Florida, Third District.
January 14, 2009.
Carlos J. Martinez, Public Defender, and Shannon P. McKenna, Assistant Public Defender, for appellant.
Bill McCollum, Attorney General, and Heidi Milan Caballero and Juliet S. Fattel, Assistant Attorneys General, for appellee.
Before CORTIÑAS, ROTHENBERG, and LAGOA, JJ.
ROTHENBERG, J.
Andre Odell Gregory ("Gregory") appeals the summary denial of his Florida Rule of Criminal Procedure 3.800 motion to correct illegal sentence. We find his claim well-taken, and reverse.
Gregory was originally sentenced to twenty years as a habitual felony offender with a fifteen-year minimum mandatory as a prison releasee re-offender. After his judgment and sentence were affirmed on appeal, Gregory filed a rule 3.850 motion for postconviction relief, alleging ineffective assistance of counsel. Pursuant to a negotiated plea between the State and Gregory, the trial court vacated Gregory's sentence, dismissed his motion for postconviction relief, and imposed a nine-year minimum mandatory sentence. The plea transcript reflects that the trial court, State, defense counsel, and Gregory knew that the imposition of a nine-year minimum mandatory sentence was not statutorily authorized, and therefore illegal. Nevertheless, despite Gregory's knowledge and his assurances that he would not file an appeal or a motion for postconviction relief challenging the minimum mandatory sentence, he has filed both, which now require judicial review.
*1288 Although it is clear that the plea was: (1) fashioned to accommodate Gregory's desire to be sentenced without being classified as a habitual offender or prison releasee re-offender; (2) entered into by Gregory freely and voluntarily with a complete understanding that the sentence was not statutorily authorized; and (3) entered into with the advice of counsel, a defendant cannot assent to an illegal sentence. Robbins v. State, 413 So.2d 840 (Fla. 3d DCA 1982). We, therefore, reverse and remand for the imposition of any sentence the trial court may legally impose.
Reversed and remanded.
