
629 N.W.2d 357 (2001)
James Charles TINDELL, Appellant,
v.
STATE of Iowa, Appellee.
No. 00-0118.
Supreme Court of Iowa.
July 5, 2001.
*358 Philip B. Mears of Mears Law Office, Iowa City, for appellant.
Thomas J. Miller, Attorney General, Kevin Cmelik, Assistant Attorney General, William E. Davis, County Attorney, and Kelly Cunningham, Assistant County Attorney, for appellee.
Considered en banc.
LARSON, Justice.
In 1995 James Tindell entered a plea of guilty to fraudulent conduct under Iowa Code sections 502A.6 and 502A.14(1) (1995). He withdrew the plea at sentencing, however, because the sentencing judge refused to grant probation. On the same day, Tindell was sentenced by a different judge, without again pleading guilty. In this postconviction-relief proceeding, Tindell argues his sentence was "illegal" because "at the time of sentencing there was no plea or finding of guilt on the record. The previous plea of guilty had been withdrawn by leave of court, and it had not been reinstated." He claims this violated statutory law and his state and federal due process rights. We hold he has waived his challenge to the sentencing procedure and therefore affirm his conviction and sentence.

I. Facts and Prior Proceedings.

On March 29, 1995, Tindell entered his plea of guilty before Judge Bobbi Alpers. The plea was entered pursuant to Iowa Rule of Criminal Procedure 9 (procedure for entering guilty plea in the presence of a plea agreement). On the morning of April 14, Tindell appeared before Judge John Nahra for sentencing. Judge Nahra refused to recognize the plea agreement, stating "I simply in good conscience cannot follow my oath and grant a period of probation when in my opinion incarceration is so clearly indicated." Tindell's counsel then asked that he be allowed to withdraw the plea of guilty and asked that the matter be set for trial. Judge Nahra granted the request to withdraw the plea.
In the afternoon of the same day, Tindell again appeared before Judge Alpers, who agreed to sentence him in accordance with the plea agreement under which he was to be granted probation. When Judge Alpers asked defense counsel whether *359 there was any "legal reason why sentence should not be imposed," Tindell's counsel replied that he knew of none.
Almost three years later, on February 5, 1998, Tindell's probation was revoked for failure to make restitution. Tindell filed a petition for postconviction relief on November 24, 1998, raising several issues not involved in this appeal. After a hearing on the petition, Judge James Havercamp discovered the guilty plea had been withdrawn by Tindell and had never been explicitly reaffirmed. This judge requested additional argument on the effect of this failure to reaffirm the guilty plea. Tindell then amended his postconviction-relief petition to include his claim that his sentence was illegal. Judge Havercamp rejected the claim of illegality and denied Tindell's motion to correct an illegal sentence under Iowa Rule of Criminal Procedure 23(5).

II. Discussion.

The sole issue on this appeal is whether, as the State argues, Tindell has waived any challenge to the sentence or, as Tindell argues, the sentence is "illegal" so as to obviate the need for objections in the district court. See State v. Woody, 613 N.W.2d 215, 217 (Iowa 2000) ("An illegal sentence is void and `not subject to the usual concepts of waiver, whether from a failure to seek review or other omissions of error preservation.'") (quoting State v. Ohnmacht, 342 N.W.2d 838, 843 (Iowa 1983)); see also Iowa R.Crim. P. 23(5)(a) ("The court may correct an illegal sentence at any time."). Our review of challenges to the illegality of a sentence is for errors at law. State v. Carstens, 594 N.W.2d 436, 437 (Iowa 1999).
Ordinarily, objections must be raised at the earliest opportunity after the grounds for the objection become apparent. State v. Johnson, 476 N.W.2d 330, 333 (Iowa 1991). Therefore, unless the sentence imposed by Judge Alpers was illegal, Tindell cannot now challenge the sentence. He does not claim to have raised any objection in the district court.
Iowa Rule of Criminal Procedure 23(5)(a), and our cases, allow challenges to illegal sentences at any time, but they do not allow challenges to sentences that, because of procedural errors, are illegally imposed. See State v. Wilson, 294 N.W.2d 824, 825 (Iowa 1980); see also 3 Charles Alan Wright, Federal Practice and Procedure § 585, at 395 (1982) ("There is a distinction between an illegal sentence and a sentence imposed in an illegal manner.").
Federal Rule of Criminal Procedure 35, which is the counterpart to our rule 23(5)(a), was amended in 1966 to allow challenges to sentences illegally imposed (as contrasted to sentences that are illegal in themselves), subject to time limitations. However, Iowa's rule 23(5)(a) still requires the sentence itself to be illegal in order to be challenged at any time. See Iowa R.Crim. P. 23(5)(a); Wilson, 294 N.W.2d at 825.
Our cases are clear that, to be "illegal" for purposes of rule 23(5)(a), the sentence must be one not authorized by statute.
The exclusion of illegal sentences from the principles of error preservation is limited to those cases in which a trial court has stepped outside the codified bounds of allowable sentencing. In other words, the sentence is illegal because it is beyond the power of the court to impose.
State v. Ceaser, 585 N.W.2d 192, 195 (Iowa 1998) (citations omitted). In Wilson we said:
The Iowa rule (as did federal rule 35 before 1966) provides that the correction may be made "at any time," strongly suggesting it is directed to excision of sentences insofar as they were beyond the *360 jurisdiction of the court and therefore void. If we were to expand that concept to encompass redress for underlying procedural defects, as well, it would open up a virtual Pandora's box of complaints with no statutorily prescribed procedures for their disposition nor any time limits for their implementation. We do not believe the legislature intended such a result. We note that federal rule 35 was amended in 1966 to provide a means for objecting to the procedure as well as the sentence itself, within prescribed time limits. We have no such provision in our rule 23(5)(a) and we may not add it by statutory construction. In short, a defective sentencing procedure does not constitute an illegal sentence under Iowa R.Crim. P. 23(5)(a). 294 N.W.2d at 825 (emphasis added).
Tindell does not claim his sentence is in excess of that prescribed by law and thus outside the jurisdiction of the court to impose. His claim of procedural error is not a claim of illegal sentence, and therefore, it is precluded by our normal error-preservation rules. We therefore affirm his conviction and sentence.
AFFIRMED.
