Real Madrid maintained their pursuit for the title by defeating Malaga 3-1 late on Saturday.
- La Liga PHOTOS: Messi's 400th goal boosts Barca title bid
Leaders Barca, who had earlier in the day beaten Valencia 2-0, have 78 points, two more than second-placed Real, with six games to go.
James Rodriguez cracked a 25-metre drive into the top corner but Real's win came at a cost with Gareth Bale and Luka Modric going off injured.
Real went ahead when Sergio Ramos volleyed home a Cristiano Ronaldo free kick after 24 minutes.
Chances went begging for both sides including a penalty miss by Ronaldo who hit the post after Samuel Castillejo had brought down Rodriguez.
Rodriguez extended Real’s lead with a fine effort after 69 minute but they had barely stopped celebrating when Malaga pulled a goal back with a header from the unmarked Juanmi.
Javier Hernandez then set up Ronaldo to score from close range in injury time.
Ronaldo scored his 50th goal of the season, and, in so doing he becomes the first player in the history of Spanish football to score 50 goals for 5 consecutive seasons.
Bale lasted only two minutes before limping off with an apparent calf injury. He is set to undergo tests as will Modric who was substituted after 59 minutes with a knee problem.
"Hopefully they are not too serious and will be fit to play Atletico," Rodriguez told reporters.
Real face Atletico on Wednesday with the scoreline 0-0 after the first leg of their Champions League quarter-final.
"It was a tough game against Malaga but we won and that is what is important," Rodriguez said.
"I have said before that you have to suffer and we are going to fight until the end to try and win the league."
Atletico's Antoine Griezmann scored twice, including a spectacular overhead kick, to secure a 2-1 win over Deportivo La Coruna that strengthened their grip on third place.
Griezmann struck with a perfectly executed bicycle kick after Jose Maria Gimenez headed the ball back into the box after five minutes played and then made it 2-0 by slotting home a loose ball.
Atletico looked firmly in control but lost concentration at the back when Oriol Riera headed in with 12 minutes left and they were put under pressure in the closing stages.
Aritz Aduriz's double, the first goal a penalty, led eighth-placed Athletic Bilbao to a 4-0 rout of 10-man Getafe.
Getafe defender Emiliano Velazquez was dismissed for upending Borja Viguera and Aduriz netted the resulting spot kick just before halftime.
La Liga PHOTOS: Messi's 400th goal boosts Barca title bid
Champions League: Oblak saves Atletico from dominant holders Real
La Liga: Ronaldo nets 300th goal for Real; Barca keep four-point lead
Ancelotti urges more consistency after Real held at Atletico
Novak Djokovic, Genzebe Dibaba bag Laureus Awards