In an action to foreclose a mortgage, the plaintiff and the intervenor separately appeal from an order of the Supreme Court, Westchester County (Nastasi, J.), entered December 9, 2004, which, in effect, granted the motion of nonparty, Francisco Mendoza, pursuant to CPLR 1003 to vacate the judgment of foreclosure and the foreclosure sale and to dismiss the complaint.
Ordered that the order is reversed, on the law, with costs, the motion is denied, and the complaint and judgment of foreclosure are reinstated.
Pursuant to CPLR 6501, the filing of a notice of pendency provides constructive notice of an action in which the judgment demanded may affect the title to real property (see Green Point Sav. Bank v St. Hilaire, 267 AD2d 203 [1999]; Goldstein v Gold, 106 AD2d 100, 101-102 [1984], affd 66 NY2d 624 [1985]). The statute further provides that a person whose conveyance is recorded after the filing of a notice of pendency is bound by all proceedings taken in the action after such filing to the same extent as if he or she were a party (see CPLR 6501; Green Point Sav. Bank v St. Hilaire, supra; American Auto. Ins. Co. of St. Louis v Sansone, 206 AD2d 445 [1994]; Goldstein v Gold, supra). *480Thus, in order to cut off an unrecorded prior lien such as a mortgage, “the purchaser must have no knowledge of the outstanding lien and win the race to the recording office” (Goldstein v Gold, supra at 101-102; see Matter of Jenkins v Stephenson, 293 AD2d 612 [2002]; Roth v Porush, 281 AD2d 612 [2001]). Here, the record demonstrates that the deed conveying a one-half interest in the subject premises to the nonparty Francisco Mendoza was recorded approximately one month after the plaintiff commenced this foreclosure action and filed a notice of pendency. Accordingly, Mendoza had constructive notice of the foreclosure action at the time his conveyance was recorded, and his interest in the premises was effectively foreclosed upon entry of the judgment of foreclosure (see Green Point Sav. Bank v St. Hilaire, supra; Westchester Fed. Sav. & Loan Assn. v H.E.W. Constr. Corp., 29 AD2d 670 [1968]). Under these circumstances, the court erred in granting Mendoza’s motion pursuant to CPLR 1003 to vacate the judgment of foreclosure and the foreclosure sale and to dismiss the complaint upon the ground that Mendoza was a necessary party (see Green Point Sav. Bank v St. Hilaire, supra; Matter of Jenkins v Stephenson, supra; Roth v Porush, supra; Goldstein v Gold, supra; Westchester Fed. Sav. & Loan Assn. v H.E.W. Constr. Corp., supra). Florio, J.P., Skelos, Fisher and Lunn, JJ., concur.