It is hereby ordered that the judgment so appealed from is unanimously modified on the law by reducing the period of postrelease supervision to a period of one year and as modified the judgment is affirmed.
Memorandum: Defendant appeals from a judgment convicting him upon his plea of guilty of criminal sale of a controlled substance in the third degree (Penal Law § 220.39) and sentencing him to a determinate term of imprisonment of six years plus five years of postrelease supervision (PRS). We conclude that the sentence is illegal insofar as the period of PRS exceeds two years ( see Penal Law § 70.45 [b]). "`Although [that] issue was not raised before the [sentencing] court or on appeal, we cannot allow an [illegall sentence to stand `"( People v Davis, 37 AD3d 1179, 1180, [2007] lv denied 8 NY3d 983). We thus conclude that the judgment must be modified with respect to the period of PRS, and we modify the judgment by reducing the period of PRS to a period of one year ( see People v Gibson, 52 AD3d 1227; People v Ehrhardt, 292 AD2d 790, lv denied 98 NY2d 675). The sentence as modified is not unduly harsh or severe.