Manchester United needed a 91st-minute winner from Marouane Fellaini to scrape a 1-0 victory over Young Boys, which seals their place in the last 16 of the Champions League with one game to spare.
It looked as though the hosts were on course for a second successive goalless draw in front of their own fans following another dreary display, which failed to entertain a sparse Old Trafford crowd.
Indeed, Jose Mourinho’s side needed David de Gea to pull off a remarkable save to keep the scores level in the second half before Fellaini struck at the death to bring a victorious end to an otherwise forgettable evening.
The bulk of the chances fell for the hosts, though, and Marcus Rashford tested Von Ballmoos again with a low drive from a tight angle after a rare piece of quick passing from United’s attackers.
It was Rashford who looked most likely to break the deadlock, but he was not clinical enough in the final third and fired a dipping low drive narrowly wide of the target after 26 minutes having been found by Jesse Lingard’s clever flick.
Another example of the home side’s wastefulness arrived four minutes before half time when Rashford latched on to a wayward pass and raced down the left flank, only to put too much on his cutback to Fellaini as Fred instead collected the ball at the back post and curled an effort wide of the far post.
Jose Mourinho opted against making a half-time substitution despite having some big names in reserve, and little changed at the start of the second half with Young Boys creating the first sight of goal when Kevin Mbabu fired into the side-netting.
United responded with a period of pressure which yielded two good chances, but first Rashford sliced well wide of the near post before Fellaini ballooned his finish over the crossbar after a poor piece of goalkeeping had gifted the Belgian a good opening.
Lingard then stung the palms of Von Ballmoos for only United’s second shot on target of the match, and Mourinho finally called upon the cavalry shortly after the hour mark as Pogba and Lukaku replaced Lingard and Fred.
Paul Pogba made a quick impact by setting up another chance for Rashford to blast wide, but United needed another big name to rescue them 20 minutes from time when De Gea pulled off a stunning save to prevent his side from falling behind against their depleted visitors.
Christian Fassnacht’s initial shot from the edge of the box did not look likely to cause many problems, but the ball took a deflection off Chris Smalling and then Mbabu before trickling towards goal. The Young Boys players were already wheeling away in celebration as the ball looked destined to cross the line, but De Gea somehow got across to claw it away.
An end-to-end period of the match ensued as Young Boys began to believe that they could steal a famous victory, with Sow drilling one free kick over before Lukaku failed to hit the target with a near-post header.
A deflected Luke Shaw strike then forced a routine save from Von Ballmoos, but again Young Boys were quickly up at the other end and Fassnacht put a promising opening high and wide from the edge of the box.
Mourinho had wanted to take Fellaini off for Juan Mata with his final change, but an injury to Valencia forced his withdrawal instead and the hosts soon went route one towards the towering Belgian, who teed up Mata for one sight of goal 10 minutes from time.
It looked increasingly as though United would fail to score in three successive home European games and fail to win in four for the first time in their history, but Fellaini popped up with the winner in the first minute of stoppage time to send those left inside Old Trafford wild.
Shaw’s long ball forward was flicked on by Lukaku for Fellaini, who turned inside the area and drilled his finish on the turn into the bottom corner – although replays raised a suspicion of handball when he initially controlled it.
No-one inside Old Trafford was worried about that, though – least of all Mourinho, who celebrated the goal by picking up a whole crate of drinks and slamming them into the ground in a mixture of relief, euphoria and frustration at what had been another underwhelming evening prior to the late winner.
Nonetheless, United can now go into their final group game away to Valencia free of worry with five points separating them from the Spanish outfit, whereas Young Boys are now consigned to finish bottom of their first ever Champions League group stage.