An 89th-minute Eduardo Salvio goal gave Atletico Madrid a 2-1 advantage to take into the second leg of their Europa League quarter-final tie against Hannover 96.
The Spaniards dominated the early stages and took the lead inside the first 10 minutes when Radamel Falcao capitalised on sloppy defending from the Germans.
Falcao almost doubled his and Atletico's tally for the evening when his header from Arda Turan's cross just cleared the crossbar, but the away side levelled with their first attack of the game.
Mame Diouf was on hand to slide the ball past Atletico keeper Thibault Courtois for an invaluable away goal after good work from Lars Stindl.
Atletico continued to put the Germans under pressure into the second half, and edged their noses in front at the death when Salvio curled in a spectacular effort.
Diego Simeone's side will likely come away wondering how they didn't win by a bigger margin, but substitute Diego almost added a third in stoppage time, testing Hannover keeper Ron-Robert Zieler with an acrobatic effort.
The result was Atletico's eighth Europa League win on the bounce.