Villarreal and Atletico Madrid continued to struggle in La Liga after both slumped to unexpected defeats on Sunday.
Cristiano Ronaldo scored twice to lead Real Madrid to a 5-0 win over La Liga new boys Xerez at the Bernabeu on Sunday.
Thierry Henry and Zlatan Ibrahimovic scored in the second half as Barcelona squeezed past bottom club Xerez 2-0 to go five points clear at the top of La Liga on Wednesday.
Cristiano Ronaldo struck twice on his return from suspension as Real Madrid crushed bottom side Xerez 3-0 away in La Liga on Saturday and trimmed Barcelona's lead at the top to two points.
Barcelona were handed their first defeat of the season by Atletico Madrid after a 2-1 loss on Sunday.
Kaka came off the bench after six weeks out injured and produced a clinical finish from Cristiano Ronaldo's assist to keep Real Madrid hot on the heels of leaders Barcelona in La Liga on Saturday. After Barca's nervy 3-1 win at home to basement side Xerez in the earlier kickoff, Brazil's World Cup-bound playmaker Kaka struck eight minutes from time to fire Real to a nail-biting 2-1 victory at 10-man Real Zaragoza.
Argentine striker Gonzalo Higuain scored twice for 10-man Real Madrid in a 2-0 home win over Getafe on Saturday that eased the pressure on coach Manuel Pellegrini. Real have 22 points from nine games and are one point behind La Liga leaders Barcelona after the champions were held to a 1-1 draw at Osasuna, Gerard Pique scoring in his own net in the last minute.