(CNN) -- Spanish champions Barcelona remained five points clear of Real Madrid despite having two players sent off against Getafe on Saturday.
Josep Guardiola's team played more than an hour with 10 men after Gerard Pique was dismissed, then substitute Rafael Marquez was ordered off in time added on to concede a penalty, but Barca still managed to pull off a 2-1 victory and remain undefeated in 21 La Liga matches this season.
Second-placed Real had no such problems in defeating Barca's city neighbors Espanyol 3-0 in the late match, keeping within two victories of their great rivals.
Barcelona took the lead after only seven minutes against visiting Getafe when world player of the year Lionel Messi curled in a superb left-foot effort for his 16th league goal in 18 appearances after a corner was not cleared.
Defender Gerard Pique then saw red for a rash lunge in the 25th minute on Rafa Lopez, who prevented the hosts from doubling their lead just before halftime with a flying block to keep out striker Zlatan Ibrahimovic's goalbound shot.
Mali midfielder Seydou Keita also should have scored but hit Getafe's sidenetting just before an hour, then a counter-attacking Messi set up stand-in captain Xavi to make it 2-0 on 67.
Mexico defender Marquez, who came on at halftime, was red-carded in the second minute of injury-time after crudely pushing Kepa Blanco from behind when he seemed set to score, and Roberto Soldado netted the resulting spot-kick.
It came too late for Getafe, who were left in seventh place, 24 points behind the leaders.
Kaka scored for the first time since November as Real Madrid cruised to victory at home to Espanyol despite being without the suspended Cristiano Ronaldo.
Defender Sergio Ramos headed home Esteban Granero's fifth-minute free-kick, while Brazil playmaker Kaka pounced to score the second goal after half an hour after goalkeeper Carlos Kameni did well to block Raul's header.
Real seemed to take their foot off the pedal in the second spell until the 90th minute when Gonzalo Higuain showed silky skills to control a long ball, evade the defense and slot his 12th league goal of the season to clinch an 11th successive league win at the Bernabeu this season.
Valencia consolidated third place with a 2-0 victory at home to Real Valladolid which left them eight points behind Real.
Midfielder Ever Banega scored in the eighth minute and Spain striker David Villa doubled the lead after half an hour as Onesimo Sanchez made a losing start top his reign as coach of the 17th-placed visitors, who could drop into the bottom three after Sunday's fixtures.