Pacos de Ferreira will stay in the Primeira Liga after beating Desportivo Aves 3-1 in the second leg of their relegation play-off.
Jorge Costa's men, who finished second bottom in the Portuguese top flight, could only manage a 0-0 draw in the first leg in Vila das Aves, leaving the tie wide open ahead of Wednesday's clash at Estadio da Capital do Movel.
But Pacos completed the job in front of their home fans, denying Aves a return to the top tier following a seven-year absence.
On-loan Manchester United forward Bebe opened the scoring in the 25th minute with his 14th goal of the campaign.
Ivorian midfielder Jean Seri then doubled the advantage a minute before the interval to seemingly put the game beyond doubt.
However, Aves - who only qualified for the play-offs due to Porto II's ineligibility for promotion - pulled one back with 12 minutes to go through midfielder Fabio Martins.
But any hopes the visitors had of completing an unlikely comeback were ended just six minutes later as Minhoca found the net for only the second time this season to preserve Pacos' Primeira Liga status.