Local media reports said Mendy could face up to a month on the sidelines in the latest setback for the France left back, who has already missed several weeks due to multiple injuries this season.
Mendy's injury adds to a growing list of absences in Real's defence, with Antonio Rudiger undergoing knee surgery earlier on Tuesday.
"Following tests carried out on our player Ferland Mendy... he has been diagnosed with a rupture of the proximal tendon of the anterior rectus in the right quadriceps," Real said in a statement.
A hamstring injury suffered in March kept Mendy out for more than a month, while a muscle injury had sidelined him for almost two weeks in December.
Real, who are four points off LaLiga leaders Barcelona going into the last five games in the campaign, host Celta Vigo on Sunday.