Saul Niguez's cool finish made the difference for Atletico Madrid as they held on to fourth place with a narrow 1-0 win at Osasuna on Sunday in La Liga.
Diego Simeone's side cut the gap on Real Sociedad in third, to four points, before the Basques visit second place Real Madrid later Sunday.
Out of the Champions League and Copa del Rey, and 13 points behind La Liga leaders Barcelona, Champions League qualification is Atletico's key goal in the second half of the season.
The Rojiblancos were left fuming after their quarter-final cup elimination in midweek, unhappy with the refereeing, but had nothing to complain about as they snatched victory at El Sadar.
Atletico took the lead after 74 minutes against the run of play, through midfielder Saul, on as a substitute.
The Spaniard is no longer a key figure for Simeone but timed a run well to reach Rodrigo De Paul's lobbed pass and finish clinically.
"(Saul) is a home-grown player who works so hard, everyone knows what he feels for the club, and he knows that this goal is very important for us," De Paul told Movistar.
"They are three vital points."
Osasuna had the better of the first half, with on-loan Barcelona winger Ez Abde offering a pacy outlet down the left.
Neither side were able to carve out a clear chance before the break, but the game soon opened up.
Jan Oblak made a superb save to deny Moi Gomez after an hour, after the midfielder burst into the box to fire Abde's cross towards goal.
The Slovenian stopper then needed to palm a deflected, dipping drive from Diego Moreno over the bar.
With Osasuna on top, De Paul fed Saul to sucker-punch them at the other end.
The 28-year-old spent last season on loan at Chelsea where he was a peripheral figure, and he is behind youngster Pablo Barrios in the pecking order this season at Atletico, with the goal a welcome morale boost.
Antoine Griezmann should have sealed Atletico's win but took a heavy touch when through on goal and then Aitor Fernandez saved the French striker's lofted effort.
Oblak tipped over another effort from Jon Moncayola as Atletico took all three points back to the capital.
Simeone believes his team bounced back well from the team's Copa del Rey elimination by Madrid.
"We have a way of thinking and working, and the club has a way of living that is to never give up, and always get up in the face of adverse situations," the Argentine coach told Movistar.
"There is no greater motivation than playing for Atletico Madrid."