Two goals in the final seven minutes earned Rangers victory in an astonishing Europa League last-32 epic against Royal Antwerp in Belgium.
Steven Gerrard's side led, then equalised twice, in the first leg of the tie, before Borna Barisic's second penalty snatched the win with two minutes of regulation time remaining.
Joe Aribo and Ryan Kent also netted for the Scottish Premiership leaders, but injuries to James Tavernier and Kemar Roofe diluted the joy a little before next Thursday's second leg at Ibrox.
Still, the dramatic late triumph leaves Rangers well-placed to reach the last-16 of the Europa League for the second consecutive campaign and maintain Gerrard's impressive European record.
It is a sign of where Rangers are now that they arrived in Belgium with little trepidation, with only Bayer Leverkusen and Young Boys managing to defeat them in their last 27 European ties.
And they were on the front foot early, and may even have had a penalty in the opening minutes for handball, but the game raged on amid a VAR check.
Tavernier tried to struggle on after an early injury, but the Rangers captain twice crumpled to the turf before being substituted midway through the half. Roofe would later limp off before the break.
Before his departure, Roofe stole into the box but could not get a clear shot at goal, then Alfredo Morelos beat the offside trap and forced the goalkeeper to block from close range.
And Rangers' positive play was eventually rewarded with the lead. Roofe chased a long ball and forced a defender to knock it back to goalkeeper Alireza Beiranvand, but he spilled and Morelos steered the ball to Aribo, who rifled home from outside the box.
Rangers had conceded just four times in their last 12 games. Now the gauntlet was laid down to Antwerp. And, within minutes, they issued their response when Felipe Avenatti headed a free-kick beyond Allan McGregor.
And with seconds to go before half-time, Rangers conceded a penalty. Lior Refaelov threw himself to the floor after Steven Davis lightly clipped the back of his foot, before picking himself up to score.
That was dramatic enough, but an even more frantic second half was to come.
Ritchie de Laet pulled the shirt of Morelos and, after the Bulgarian referee was advised to check the incident on the pitchside monitor, Rangers had a spot-kick of their own.
Barisic scored but, again, as Rangers went on the front foot they were sucker-punched at the back. Martin Hongla tried his luck from distance, and nestled the shot into the back of the visitors' net.
Rangers went again, and perhaps should have levelled when Ianis Hagi jabbed a near-post cross wide. But they kept pressing, and Kent took the ball past a defender and lashed in a fine finish to level with seven minutes to play.
Both sides had chances to win it. Replacement goalkeeper Ortwin de Wolf stretched out a leg to deny Kent, then McGregor did the same at the other end before Ryan Jack made a goal-line clearance.
And then it was a second spot-kick after Abdoulaye Seck handled Kent's shot, receiving a red card for his troubles. Barisic took a deep breath and scudded in his second of the night as time ran out.
Even then the action was not over, with Koji Miyoshi cracking a late effort off the post for the hosts. But Rangers survived for a win that should take them a long way towards a place in the last 16.