Super sub Eric Maxim Choupo-Moting struck the stoppage-time winner.
Costa turned Juanfran's low cross into the net in the 69th minute for Atletico's third goal in the first leg of the last 16 tie against third division Lleida but immediately limped to the sidelines. He did return to the pitch, however, and completed the game despite bleeding from his knee.
The former Real Madrid striker is expected to make his Liverpool debut in their lunchtime game against Manchester United at Anfield.
La Liga leaders Barcelona were held to a 2-2 home draw by Celta Vigo on Saturday as their former assistant coach Juan Carlos Unzue dented the title hopes of the Catalans, who dropped points for the second game in a row for the first time this campaign.
A Thierry Henry special and two trademark free kicks from Ronaldinho earned Barcelona a 3-0 win at home to Real Betis that put them within a point of leaders Real Madrid at the top of the Primera Liga on Sunday.
Just as he did two years ago, Sergio Ramos left his footprint all over Real Madrid's Champions League final triumph over Atletico Madrid following a turbulent 12 months.
Atletico Madrid coach Diego Simeone rates Antoine Griezmann as one of the top three players in the world and says the forward owes it to his ability to work hard and the willingness to listen.
Barcelona coach Luis Enrique has decided to rest Lionel Messi, Neymar and most of his regulars for the King's Cup last 16, second leg match at Elche later on Thursday.
Kingsley Coman scored one goal and set up another as Bayern Munich came from a goal behind to beat VfB Stuttgart 3-1 on Saturday and defend their top spot in the Bundesliga.
Villarreal's Brazilian midfielder Marcos Senna tested positive for two banned substances.
Barcelona continued their rampant run of domestic form to beat Osasuna 2-0 away from home on Saturday and move to within two points of La Liga leaders Atletico Madrid, with Lionel Messi setting up goals scored by Jordi Alba and teenager Ilaix Moriba.
Valencia midfielder Pablo Aimar was discharged from hospital on Sunday after spending the night under observation after a blow to the head.
Striker Fernando Torres has been released from hospital, his club Atletico Madrid said on Friday, after sustaining a head injury during Thursday's 1-1 draw at Deportivo La Coruna.
The Spain coach has given his players one last chance to impress this weekend before he names his World Cup squad on Monday.
Champions Bayern Munich needed an 88th-minute winner by Joshua Kimmich to beat Hamburg SV 1-0 on Saturday and protect their three-point lead at the top of the Bundesliga. Strugglers Hamburg had battled hard to protect a goalless draw and end a three-game losing run, with goalkeeper Rene Adler making a string of key saves before Kimmichdrilled in a Franck Ribery cutback at the far post. The result lifted Bayern to 15 points, three ahead of Borussia Dortmund, who beat Freiburg 3-1 on Friday.
IMAGES from football matches played across leagues in Europe on Sunday.
Real Madrid swatted aside Granada 4-1 on Thursday to ensure the La Liga title race will go down to the wire.
Barcelona's bid for a fifth La Liga title in six years suffered a surprise setback when the champions crashed to a 1-0 defeat at lowly Real Valladolid on Saturday.
Zinedine Zidane's Real side demonstrated their new-found grit to re-take the lead
Playmaker Zinedine Zidane and defender Ivan Helguera were also included in the Real Madrid squad despite nursing injuries.
The Brazilian has been criticised by Real fans for below-par performances and hinted last week he wanted to leave.
A round-up of Sunday's matches in La Liga, Serie A and Bundesliga.
David Beckham will miss the tour opener in the United States as his club Real Madrid want him to continue despite picking up a ban.
Striker Costa ends second spell at Atletico Madrid.
Goa slipped to fourth and have eight points.
Atletico Madrid's problems deepened as they were held to a 0-0 draw at Villarreal in La Liga on Friday, stretching their winless run to four games in all competitions.
A round-up of weekend action in the main European leagues.
Real Madrid ran riot to sink Espanyol 4-0 at the Bernabeu in the Spanish Primera Liga.
Holders Barcelona crashed out of the Champions League after being stifled by a brilliantly well-organised Atletico Madrid.
The home side spurned two chances to extend their advantage before the break but Barca levelled in the 52nd minute when Luis Suarez glanced in Lionel Messi's free kick.
PES 2018 does add some value to the genre, says Kakoli Chakraborty.
Cristiano Ronaldo and Gareth Bale both scored as Real Madrid staged a remarkable late comeback from two goals down to win 3-2 at Villarreal and stay top of La Liga.
A round-up of weekend action in the major European leagues.