
864 So.2d 492 (2004)
Thomas B. WHEELER, Appellant,
v.
STATE of Florida, Appellee.
No. 5D02-2769.
District Court of Appeal of Florida, Fifth District.
January 2, 2004.
James B. Gibson, Public Defender, and Barbara C. Davis, Assistant Public Defender, Daytona Beach, for Appellant.
Charles J. Crist, Jr., Attorney General, Tallahassee, and Rebecca Roark Wall, Assistant Attorney General, Daytona Beach, for Appellee.
THOMPSON, J.
Thomas B. Wheeler appeals his sentence and the denial of his motion to withdraw plea.
We find no abuse of discretion in the denial of the motion to withdraw plea and affirm the order.
We agree with Wheeler, however, that his sentences for burglary are illegal. Wheeler pleaded guilty to five counts of burglary of a dwelling, among other crimes, in exchange for the state's recommendation that Wheeler be sentenced to between 25 and 35 years in prison. The court sentenced him to 25 years for each of the burglaries. Burglary of a dwelling is a second-degree felony under section 810.02(3), Florida Statutes (1999), and is punishable by a maximum term of 15 years under section 775.083(3)(c), Florida Statutes (1999). A sentence can exceed the statutory maximum, but only if the lowest permissible sentence under the sentencing code exceeds the statutory maximum. Rule 3.704(d)(25), Fla. R.Crim. P.; § 921.0024, Fla. Stat. (1999). The lowest permissible sentence for each of the burglaries was 165.6 months, or 13.80 years. Because the lowest permissible sentence was 13.80 years, the maximum permissible sentence was 15 years.
A sentence which exceeds the statutory maximum is an illegal sentence,compare Davis v. State, 661 So.2d 1193, 1196 (Fla.1995), and an illegal sentence cannot be imposed even as part of a negotiated plea agreement, Wright v. State, 743 So.2d 103 (Fla. 1st DCA 1999). The state argues that the sentences were not illegal because the court could have achieved an overall sentence of 25 years by ordering five-year sentences, which Wheeler also received, to run consecutive to the burglary sentences. We do not agree because the fact that the court could have imposed consecutive sentences *493 does not cure the illegality of the sentences actually imposed. Similarly, the fact that the court may order consecutive sentences on remand does not cure the illegality of the sentences. Compare Leonard v. State, 760 So.2d 114, n. 4 (Fla. 2000) (holding that illegal sentence should not remain uncorrected merely because it was to be served concurrent to another sentence). Accordingly, we vacate the sentences for burglary of a dwelling imposed in case numbers CR99-17100, CR99-17101, CR00-569, CR00-368, and CR00-730. However, because the sentences were the result of a plea agreement with the state, the state should be given the option on remand "of either agreeing that both the judgment and sentence should be vacated and taking the defendant to trial on all original charges, or agreeing that only the excessive sentence should be vacated, while making the judgment stand and allowing the defendant to be resentenced." Jolly v. State, 392 So.2d 54, 56 (Fla. 5th DCA 1981).
AFFIRMED in part; VACATED in part; and REMANDED with instructions.
PETERSON and TORPY, JJ., concur.
