Real Madrid has announced that defender Dani Carvajal has been diagnosed with a viral infection that is affecting his pericardium, the membrane enclosing the heart.

The 25-year-old featured in the 3-1 UEFA Champions League win over Borussia Dortmund during the week and has started all six of his side's LaLiga matches so far this season.

That run is expected to come to an end on Monday (AEST), with the combative full-back poised to miss the home clash against Espanyol.

Carvajal had been named in Spain's squad for its final two FIFA World Cup qualifiers against Albania and Israel next week, but it now appears likely that he will miss those matches as well.

No timeframe has been given for his return to action with Madrid stating he "will continue to be assessed".