opinion of the court
Mollen, P. J.On this appeal, the defendant challenges the validity of two narcotics convictions. He contends that those convictions must be overturned as a consequence of the fact that, in several prior criminal proceedings, he was represented by a layman who falsely represented himself as an attorney at law.
In 1972, the defendant was the subject of three separate Nassau County indictments and of three additional accusatory instruments all filed in Nassau County. Repre*462sented by one Albert Silver, the defendant entered guilty pleas to two felony narcotics offenses and two misdemeanor narcotics offenses in full satisfaction of all pending charges. As part of the plea bargain, a charge of criminal possession of stolen property was dismissed.
In 1977, the defendant was again named in two Nassau County indictments, each charging him, inter alia, with selling drugs. At the trial on the first indictment (No. 45711), the defendant raised the affirmative defense of entrapment and the defense of agency. In anticipation of those defenses, the prosecutor sought and was granted permission to introduce in his direct case evidence relating to the defendant’s prior drug-related activity. Consequently, testimony was elicited to establish that the defendant had previously sold narcotics to police officers, and that those sales had resulted in his having been twice indicted and twice convicted for narcotics offenses in 1972. Certified copies of the defendant’s convictions were received in evidence. In addition, when the defendant took the stand in his own behalf, the prosecutor attempted to impeach his credibility by questioning him regarding the facts underlying the 1972 stolen property charge which had been dismissed as part of the plea bargain.
At the trial on the second indictment (No. 45712), the defendant simply denied the charges against him. Again, however, when he took the stand in his own behalf, the prosecutor questioned him on the facts underlying the 1972 stolen property charge. No evidence was introduced regarding the defendant’s prior narcotics activities.
The defendant was ultimately convicted in each case, and both convictions were affirmed (see People v Pilgrim, 67 AD2d 554, affd 52 NY2d 730; People v Pilgrim, 69 AD2d 825). Following those affirmances, the defendant learned that the Albert Silver who had represented him on the 1972 charges was not in fact a licensed attorney. As a result, pursuant to CPL article 440, the defendant moved to vacate his 1972 felony convictions on the ground that they were invalid owing to a denial of his constitutional right to counsel. The defendant further sought the vacatur of his 1977 convictions on the ground that, at the trials of *463those cases, the prosecution had made use of the earlier invalid convictions.
With the prosecutor’s consent, the County Court vacated the defendant’s 1972 felony convictions. The court refused, however, to vacate the 1977 convictions rendered under Indictments Nos. 45711 and 45712, although it directed that the defendant be resentenced in those cases to eliminate the possibility that the invalid 1972 convictions had been considered in the sentencing process (111 Misc 2d 842). It is from the court’s refusal to vacate the two 1977 convictions that the defendant now appeals.
The County Court correctly found that the defendant’s 1972 felony convictions were invalid because they were rendered in violation of his right to counsel (see People v Felder, 47 NY2d 287). The question presented here is whether that violation now requires that the defendant’s subsequent convictions be vacated as well.
In Burgett v Texas (389 US 109, 115), the court wrote: “To permit a conviction obtained in violation of Gideon v. Wainwright to be used against a person either to support guilt or enhance punishment for another offense * * * is to erode the principle of that case. Worse yet, since the defect in the prior conviction was denial of the right to counsel, the accused in effect suffers anew from the deprivation of that Sixth Amendment right.”
The use of a prior invalid conviction at trial, although error, requires reversal only if it can be said that it “might well have influenced the outcome of the case” (Loper v Beto, 405 US 473, 480). At bar, the County Court held that the outcome of the defendant’s 1977 cases was not influenced by the references to his prior convictions and that, therefore, any error was harmless. With respect to the conviction rendered under Indictment No. 45711, we disagree.
Most frequently, where courts rule that the use of a prior invalid conviction is harmless error, the issue arises in the context of a prosecutor’s attempt to impeach a testifying defendant’s credibility (see, e.g., Zilka v Estelle, 529 F2d 388, cert den 429 US 981; United States v Faulkenbery, 472 F2d 879, cert den 411 US 970; Tucker v United States, 431 F2d 1292, affd 404 US 443). At trial under Indictment No. *46445711, however, the prosecution used the prior convictions, not merely as a means of impeaching the defendant’s credibility, but as an important element of its direct case to disprove agency and refute the claim of entrapment. In such circumstances, we cannot conclude that the error was harmless beyond a reasonable doubt. Accordingly, the conviction rendered under. Indictment No. 45711 must be vacated and the defendant afforded a new trial thereon.
In contrast, the conviction rendered under Indictment No. 45712 need not be overturned. At the trial of that indictment, the defendant was asked only one question regarding his alleged possession of stolen property in 1972. We are not persuaded that the fact that he was represented by a noníawyer on a charge growing out of that alleged possession — a charge which was ultimately dismissed as part of a plea bargain — should insulate him from otherwise appropriate impeachment inquiry as to the facts underlying that charge. Finally, the inquiry concerned only the defendant’s alleged acts, not any unconstitutional conviction. Accordingly, the County Court properly denied so much of the defendant’s motion as sought to vacate the conviction under Indictment No. 45712.
Gulotta, Brown and Niehoff, JJ., concur.
Upon appeal by permission, order of the County Court, Nassau County, entered November 9, 1981, modified, on the law, by vacating the conviction under Indictment No. 45711 and new trial ordered thereon. As so modified, order affirmed insofar as appealed from, and matter remitted to the County Court, Nassau County, for further proceedings.