Opinion by Judge WARDLAW. Partial Concurrence and Partial Dissent by Judge KLEINFELD.
OPINION
WARDLAW, Circuit Judge.Samuel Arellano-Gallegos appeals his 51-month sentence imposed following his guilty plea to illegal re-entry after deportation in violation of 8 U.S.C. § 1326(a). Arellano challenges the waiver provision in his plea agreement, and claims the district court erred by failing to acknowledge its discretion to depart downward pursuant to U.S.S.G. § 5K2.0. We have jurisdiction pursuant to 28 U.S.C. § 1291 and 18 U.S.C. § 3742(a)(1), and we reverse.
I.
In his written plea agreement, Arellano agreed to waive his right to appeal the imposition of sentence upon him. The magistrate judge who took his plea upon consent, see United States v. Reyna-Tapia, 328 F.3d 1114 (9th Cir.2003) (en banc), cert. denied, — U.S. -, 124 S.Ct. 238, 157 L.Ed.2d 182 (2003), failed to adhere to the requirements of Rule 11 regarding the waiver of appeal. Rule ll(b)(l)(N) (2002) (formerly Rule 11(c)(6) (1999)) mandates that:
Before the court accepts a plea of guilty ... the court must address the defendant personally in open court. ... During this address, the court must inform the defendant of, and determine that the defendant understands ... the terms of any plea-agreement provision waiving the right to appeal or collaterally attack the sentence.
Fed.R.Crim.P. ll(b)(l)(N).
The magistrate judge then filed with the district court “Findings and Recommendation Upon a Plea of Guilty and District Judge’s Acceptance of Plea of Guilty.” These findings and recommendations again omitted any reference to the waiver of appeal. The district court nevertheless accepted Arellano’s plea of guilty by signing the form on October 3, 2000. No mention of the waiver of appeal was ever made in open court until the time of sentencing on April 25, 2001, when, in passing, the district court noted that “[t]he record shows that [Arellano] waived his right to appeal.”
We conclude that, given these facts, the failure to comply with Rule 11 constituted plain error within the meaning of United States v. Vonn, 535 U.S. 55, 59, 122 S.Ct. 1043, 152 L.Ed.2d 90 (2002). Neither the magistrate judge nor the district court ascertained whether Arellano’s waiver of appeal was knowing and voluntary “before” the acceptance of the plea, as Rule 11 requires. See also United States v. Anglin, 215 F.3d 1064, 1068 (9th Cir.2000) (“The sole test of a waiver’s validity is whether it was made knowingly and voluntarily.”). Indeed, unlike in United States v. Ma, 290 F.3d 1002 (9th Cir.2002), relied upon by the government, the plea waiver was never mentioned in open court prior to the acceptance of the plea. In Ma, the government summarized the appellate waiver in open court. The court asked Ma’s counsel if what had been presented agreed with his understanding and if he had discussed these matters with his client. Defense counsel responded affirmatively. The court then asked Ma if the *968summary comported with her understanding of the plea agreement, and Ma also responded affirmatively on the record. Id. at 1004. Thus, in Ma, the judge’s omission was not plain error, because during the plea colloquy and before acceptance of the plea, the government covered the same ground the court should have, and Ma affirmatively indicated she agreed with the government’s summary of the plea agreement. In contrast, here, the magistrate judge asked each defendant1 only the general questions whether they had read and understood their “five or six-page plea agreement,” and made no specific reference to the waiver of the right to appeal the sentence. The sentencing judge’s comment “The record shows he waived his right to appeal,” does not satisfy the requirements of Rule 11 either. The sentencing judge neither “address[ed] the defendant personally” regarding the waiver nor “determine[d] that the defendant un-derst[ood]” the meaning of the waiver. And, obviously, the district court’s casual statement was made some six months after the plea had been accepted.
Because this was not a technical violation of Rule 11, but rather a wholesale omission, and there is nothing elsewhere in the record to indicate that Arellano understood the right to appeal his sentence, his substantial rights were affected. See United States v. Minore, 292 F.3d 1109, 1118 (9th Cir.2002), cert. denied, 537 U.S. 1146, 123 S.Ct. 948, 154 L.Ed.2d 848 (2003) (“[A] defendant’s substantial rights are affected by Rule 11 error where the defendant proves that the court’s error was not minor or technical and that he did not understand the rights at issue when he entered his guilty plea.”). And, because there was a “wholesale failure” to comply with Rule 11 or otherwise ensure that Arellano understood the consequences of waiving his right to appeal the sentence which had yet to be imposed, the enforcement of the waiver in these circumstances would seriously affect the fairness, integrity and public reputation of our plea proceedings. See United States v. Pena, 314 F.3d 1152, 1158 (9th Cir.2003).
II.
Arellano argues the district court erred by faffing to acknowledge its authority to depart downward pursuant to U.S.S.G. § 5K2.0. See Koon v. United States, 518 U.S. 81, 92, 116 S.Ct. 2035, 135 L.Ed.2d 392 (1996) (noting that district courts have statutory authority to depart from the Guidelines); see also United States v. Dickey, 924 F.2d 836, 839 (9th Cir.1991) (remanding for clarification where doubt existed as to whether the district court had exercised its discretion in denying a downward departure). We are unable to determine on the basis of this record whether Arellano’s claim of sentencing error is valid. The district court did not expressly acknowledge that it understood it had the authority to depart, saying only “[tjhat’s the best I can do.” Its only express reference to “departure” was a prediction that “it is only going to get worse, not better ... [as] the sentencing commission is trying to take out any possible departures.” Therefore, we must remand for resentencing.
REVERSED and REMANDED.
. The magistrate judge took the pleas of two defendants in unrelated cases simultaneously, which may explain the omission.