The People appeal an order by the Appellate Division that reversed a judgment **567*790by Supreme Court, vacated defendant's pleas, and dismissed the defendant's indictment without prejudice, allowing the People to re-present any appropriate charges to another grand jury ( People v. Smith, 143 A.D.3d 31, 37 N.Y.S.3d 4 [1st Dept 2016] ). Contrary to the People's claim, the Appellate Division correctly determined that the trial court denied defendant's right to counsel on the People's motion to compel defendant to ***629submit to a buccal swab.1 Nevertheless, the Appellate Division's order should be modified, because the indictment should not have been dismissed.
Defendants have a constitutional right to counsel at every critical stage of the proceedings, meaning those stages that hold "significant consequences for the accused" ( Bell v. Cone, 535 U.S. 685, 696, 122 S.Ct. 1843, 152 L.Ed.2d 914 [2002] ; see also People v. Settles, 46 N.Y.2d 154, 165, 412 N.Y.S.2d 874, 385 N.E.2d 612 [1978] ). Here, the People filed their motion to compel the DNA test and served the motion on retained counsel in court. As the Appellate Division found, the trial court-in defendant's absence2 -subsequently granted both the retained defense counsel's motion to be relieved from representing defendant for failure to pay his fee and the People's DNA discovery motion, which it granted based on the "putative consent" it inferred from retained counsel's silence. Later the same day that counsel was relieved, defendant appeared in court. Knowing defendant was unrepresented, the court, rather than remain neutral, proceeded to act in place of counsel throughout an extensive colloquy, telling defendant that there were no bases on which to challenge the DNA sample order. In response to the court, defendant stated that he had not spoken with his attorney about the prosecution's motion and did not wish to consent to giving a sample. Notwithstanding defendant's entreaties, the court rejected his repeated requests for an attorney to advise him regarding the motion. Instead, the court told defendant "an attorney [was] not going to be able to help," and that there was "no basis for fighting [the test]." When defendant said he did not "know the law," the judge responded "I know the law." On these facts, the Appellate Division correctly determined that "[t]he pretrial proceedings concerning the DNA test were 'critical' within the meaning of the law" ( Smith, 143 A.D.3d at 35, 37 N.Y.S.3d 4 ). Accordingly, defendant was deprived his right to counsel.3
We reject the dissent's conclusion that defendant was not denied counsel during a critical stage of the proceeding, as that ***630determination is contrary to law and would require that we distort the factual record. As the People concede, there was no express consent to their request for the DNA sample, either by defendant or by retained counsel. Nor was there any affirmative conduct or errant statement by defendant or counsel from which implied consent could be inferred. Instead, as the People acknowledge, the court issued its order based only on retained counsel's failure to reply to the People's motion to **568*791compel the buccal swab. Under the circumstances here, that is not a proper basis for finding defendant's consent.4 Further, as the record unambiguously shows, shortly after the court granted retained counsel's request to withdraw-leaving defendant unrepresented-defendant appeared in court, expressly denied consent, and repeatedly stated he wanted counsel to assist him in responding to the People's motion.5 Yet, rather than appointing counsel, the court told defendant there was no basis to oppose the motion. Notwithstanding these facts, the dissent believes defendant was represented on the motion for the DNA sample; we do not.
The dissent also mistakenly ascribes to our narrow decision some previously-unannounced, broad rule. Here, we solely apply settled law to the facts before us. Where the court grants counsel's motion to be relieved from the case in defendant's absence but orders the taking of a DNA sample based on that counsel's inaction, and defendant at the first opportunity denies consent and requests assistance of counsel on that motion, the court may not deny the request and inform an unrepresented defendant that, in the court's opinion, there is no legal recourse. Thus, we conclude defendant was denied his right to counsel in violation of the Sixth Amendment and Article I, § 6 of the New York State Constitution.
The legality of the remedy for that error is subject to our review pursuant to CPL 470.35(2)(c). Based on the nature ***631and timing of the constitutional deprivation at issue here, the dismissal of the indictment was not an appropriate corrective action. Under CPL 470.20, the Appellate Division may take "such corrective action as is necessary and appropriate both to rectify any injustice to the appellant resulting from the error or defect which is the subject of the reversal or modification and to protect the rights of the respondent." The violation of defendant's right to counsel, although serious, occurred post-indictment and did not retroactively infect the grand jury proceedings. Nevertheless, the violation resulted in defendant being denied the opportunity to confer with counsel regarding a potential challenge to the taking of inculpatory DNA evidence. This warranted the Appellate Division vacating defendant's pleas. Dismissal of the indictment, however, was not "necessary and appropriate" to rectify the injustice to the defendant.
Accordingly, the order of the Appellate Division should be modified by reinstating the indictment and remitting the case to Supreme Court for further proceedings in accordance with this opinion and, as so modified, affirmed.
As defendant admits, he has no right to have counsel present during the physical administration of the buccal swab.
When the court officer informed the court that defendant had yet to be produced, retained counsel waived defendant's production in this matter.
This is not a case in which defendant asserts an ineffective assistance of counsel claim based on matters dehors the record, which would be properly addressed in a CPL 440.10 motion (People v. Jackson, 29 N.Y.3d 18, 24, 52 N.Y.S.3d 63, 74 N.E.3d 302 [2017] ). The colloquy between the court is on the record, and it is undisputed that defendant was unrepresented at that time.
The fact that a court may generally treat counsel's failure to object as an affirmative decision not to challenge an adversary (dissenting op. at 634, 69 N.Y.S.3d at 570-71, 92 N.E.3d at 93-94) is irrelevant to the matter before us where the court's improper actions are independent of an order issued based on counsel's "putative" consent. The record here establishes that the court acknowledged defendant's objections and requests for an attorney, and yet sought to persuade defendant to acquiesce to the DNA test without benefit of counsel.
Contrary to the dissent's suggestion (dissenting op. at 634, 69 N.Y.S.3d at 570-71, 92 N.E.3d at 793-94), defendant has always maintained that he did not consent to the DNA test. In fact, the court engaged in a substantive colloquy because of defendant's refusal to consent, not in spite of his counsel's putative consent.