A pair of inspired substitutions from coach Ottmar Hitzfeld earned Switzerland a 2-1 comeback FIFA World Cup win over Ecuador in Group E.
The in-form Enner Valencia scored his fifth goal in the past five international appearances to give the South American team a 22nd-minute lead but Admir Mehmedi levelled three minutes after coming on as a half-time substitute.
Both those goals came about as a result of poor set-piece marking, but Switzerland took the points in dramatic fashion courtesy of a clinical counter-attack deep into injury time.
Mehmedi’s fellow replacement Haris Seferovic, who last netted for his club Real Sociedad in November, was on hand to convert Ricardo Rodriguez's low cross to spark wild celebrations from the Swiss.
Ecuador made high-tempo start, launching attack after attack during the opening minutes but the Switzerland defence stood firm.
Their lone striker, Josip Drmic, had a sight of goal in the 12th minute, only for Jorge Guagua to make a timely challenge as the Europeans found their feet.
Granit Xhaka and Xherdan Shaqiri tried their luck from outside the box - the latter's strike grasped at the second attempt by goalkeeper Alexander Dominguez, who then spilt a 19th-minute shot from full-back Rodriguez behind.
And so it was slightly against the run of play when Valencia headed home Walter Ayovi's pinpoint delivery as Switzerland's customary set-piece solidity deserted them.
Valencia has played a more forward role in the Ecuador team since the death of Christian Benitez last July and, as part of their celebrations, the Ecuador players pointed to the sky, apparently in tribute to their late team-mate.
Dominguez showed more assured handling when Valon Behrami headed Shaqiri's corner goalwards and the Ecuador goalkeeper then got a vital touch to send Gokhan Inler's low 36th-minute drive around the post.
Ecuador looked to extend their lead two minutes before the break but Johan Djourou made last-ditch block to deny Jefferson Montero after Felipe Caicedo had played the winger in.
Mehmedi was introduced at the resumption and Hitzfeld's decision to bolster his attack paid almost instant dividends.
Just as Switzerland's marking was found wanting for the game's opening goal, Ecuador allowed the Freiburg forward far too much room to head Rodriguez's corner into the net.
Both teams refused to take a backwards step following the equaliser, Valencia remaining heavily involved as he weaved inside to ripple to top of the netting with an hour played.
Ecuador's pace on the counter-attack became an increasing threat and Diego Benaglio made a fine save after his defenders backed off the rampaging Montero, while Drmic scrambled the ball home from an offside position at the other end with 20 minutes to go.
Shaqiri drilled into the side netting with team-mates well placed inside him, while Valencia almost capitalised on a rush of blood from Benaglio, but the goalkeeper was let off the hook.
Ecuador sub Michael Arroyo erred in delaying his shot in stoppage time, allowing Switzerland to break and after Behrami had made a superb tackle to set them away, Seferovic made no such mistake when he fired home the winner with virtually the last kick.
Switzerland must tackle France in Salvador on Friday, while Honduras are next up for Ecuador later on the same day in Curitiba.
|Emery desperate to win Coupe de France|
|Toronto 5 Columbus Crew 0: Eastern Conference leaders cruise|
|Hazard unfazed by comparisons to ´leaders´ Messi, Ronaldo|
|Zidane hails ´extraordinary´ Buffon|
|Wenger to give away FA Cup medal if Arsenal beat Chelsea|
|Conte eyes Chelsea extension to reward Abramovich faith|
|Gerrard to take on Man Utd again in Carrick´s testimonial|
|Bernardo hoping to learn Silva service from Manchester City star namesake|
|I´m still a Colchonero – Griezmann rejects claims Man Utd deal is done|
|Tearful Mbappe wishes Bernardo Silva well at Manchester City|
|WATCH: Pablo Zabaleta surprises Manchester City fans|
|Bernardo Silva: You don´t say no to Pep Guardiola!|
|Manchester City swoop for Monaco star Silva|
|Wenger: Arsenal stadium move the most difficult time of my life|
|Tuchel has ´goosebumps´ from Dortmund´s Pokal run|
|Sanchez named Arsenal´s Player of the Year as Ozil misses top three|
|Ronaldo agreed he needed more rest, says Zidane|
|Outgoing Barcelona boss Luis Enrique vows he will not change|
|Bale resumes Real Madrid training ahead of Champions League final|
|Neymar has evolved but he needs trophies, says Luis Enrique|
|Passionate Totti should play on, says Conte|
|Baby, I´m coming home! Evra could not be happier about Old Trafford return|
|Liverpool youngster Woodburn ´never really considered´ swapping Wales for England|
|Gattuso completes AC Milan return|
|Kitchee 1 Tottenham 4: Son, Kane strike as Spurs round off season in style|
|Coutinho perfect for Barcelona - Tite|
|Luis Enrique accepts he has not pleased everyone at Barcelona|
|He´s one of the greatest - Conte does not expect Wenger to leave Arsenal|
|Pogba would have left for €60m had we inserted buyout clause - Marotta|
|Sevilla and Argentina reach agreement on Sampaoli|
|Pique says referees ´have influenced LaLiga´ as Barcelona defender again calls for VAR|
|Valencia signs Manchester United extension|
|West Ham snap up Zabaleta|
|Luis Enrique needs more than Copa del Rey to secure place in Barcelona history|
|Juventus not resting Dybala and Higuain ahead of Champions League final|
|Champions League final to be played under closed roof for first time|
|Allegri keen to open contract talks with Juventus|
|Darmian wants Manchester United stay|
|Familiar surroundings, but uncertainty shrouds Arsenal´s 20th FA Cup final|
|Stoke tie down Cameron, Bardsley as Given departs|
|Asensio: Zidane used to be my idol|
|RB Leipzig rule out Keita, Werner and Forsberg sales amid Liverpool links|
|Pokal glory should force Watzke and Tuchel to kiss and make up|
|Oxlade-Chamberlain studying Alves before FA Cup final|
|PSG have gone backwards under Emery – Coupe de France glory won´t change that|
|Klopp can attract top players to Liverpool, says Gerrard|
|Napoli block Milik and Zielinski from Poland U21 duty|
|The curious case of Costa - how Diego will be remembered if he leaves Chelsea|
|He is not a hero, he is a God - Eriksson hails departing Roma icon Totti|
|Copa Libertadores Review: Gremio storm into last 16, Guarani through|
|Chicago Fire 2 FC Dallas 1: Schweinsteiger´s men stay hot with fourth straight win|
|Keane: Football is unimportant after Manchester attack|
|Prandelli to replace Petrescu at Al Nasr|
|Zaha signs long-term Palace deal|
|Barca offered more money but Vinicius preferred Madrid - Pena|
|David Luiz took pay cut to return to Chelsea|
|Eredivisie play-off between MVV and Roda halted by crowd trouble|
|No way forward for Monk at Leeds amid Middlesbrough links|
|Troyes 2 Lorient 1: Late Nivet strike settles play-off first leg|
|Wolfsburg 1 Eintracht Braunschweig 0: Gomez penalty earns first-leg lead|
|Gattuso denies return to AC Milan is a step back|
|Man Utd´s Europa League title gave Manchester a lift - Ferguson|
|Arbeloa, Calleri and Tore leave West Ham|
|Hull City confirm Marco Silva exit|
|I really want a title - Sokratis hints at Dortmund departure|
|Italy include Berardi in experimental squad to face San Marino|
|Man Utd boss Mourinho gets his way on Rashford as Southgate backs down over Under-21s|
|Norwich appoint Farke as Neil´s successor|
|Monk leaves Leeds after Radrizzani takeover|
|Arsenal must get in Hazard´s face, says Ramsey|
|Sagna departs as Manchester City exodus continues|
|Moses has no plan to stop Arsenal star Sanchez|
|Caballero the latest to depart Manchester City|
|England boss Southgate explains dropping Rooney|
|Cillessen could consider Barcelona exit in January|
|Navas leaves Manchester City|
|Man Utd captain Rooney: I have lots of offers|
|Manchester City confirm Clichy departure|
|Mandzukic extends Juventus deal to 2020|
|Suarez out for 15 days with thigh injury|
|Ronaldo in Portugal´s Confederations Cup squad as Sanches misses out|
|Totti confirms Genoa will be his final Roma game|
|´Arsenal win would be a shock – Mertesacker is playing!´|
|Playing with Cristiano Ronaldo still hasn´t sunk in, says new Real Madrid signing Vinicius Junior|
|Liverpool goalkeeper Manninger to retire|
|He loves us! – Levy certain Pochettino will stay at Tottenham|
|Rooney left out of England squad to play Scotland and France|
|Herrera would welcome Griezmann at Manchester United|
|City and United join forces with £1m donation to Manchester emergency fund|
|Iniesta unsure over long-term Barcelona future|
|Makelele role is now the Kante role - Chelsea icon Claude passes baton to N´Golo|
|Willian wants Chelsea stay amid Manchester United rumours|
|Boateng rules out Bayern exit|
|Klopp wants Liverpool transfer dealings wrapped up as soon as possible|
|Barcelona express Messi support after lost appeal|
|Valverde a good option for Barcelona – Pique|
|Pogba: I´d be very happy if Juve won Champions League|
|Copa Libertadores Review: Palmeiras, Wilstermann progress|
|Chinese FA cracks down on soaring transfer fees to place Costa deal in doubt|
|Mata and Smalling describe extra Europa League motivation after Manchester attacks|
|Herrera dedicates Europa League trophy to Manchester victims|
|Bosz admits Ajax were overawed by Stockholm showpiece|
|From ´The Special One´ to ´The Humble One´ - Mourinho felt he was the worst manager in the world|
|Mourinho plays down talk of Silva move|
|Atletico Madrid don´t expect Manchester United to match Griezmann´s €100m clause|
|Ibrahimovic: My future? Let´s see|
|Mourinho wants Rooney stay and urges Woodward to start working on transfers|
|Poets don´t win titles – Mourinho defiant after Ajax criticise Manchester United approach|
|Bosz unimpressed by Manchester United: Ajax did not have to lose to this team|