A sobbing Ronaldo was consoled by his team after a brilliant save of his penalty kick by Jan Oblak in the 105th minute. But during the shootout, he managed to convert Portugal's first effort while Portugal goalie Diogo Costa saved kicks from Josip Ilicic, Jure Balkovec and Benjamin Verbic to send his team in the final eight.
Costa's fine efforts near the nets allowed Bernardo Silva to score the winning kick after Bruno Fernandes had also scored and had also pulled off a brilliant one-on-one save from Benjamin Sesko during the extra-time, preventing Slovenia a chance to pull of a shocker.
Ronaldo dominated the encounter though, as he was a man on a mission to open his goal tally at the tournament after missing out on the nets in the group stage, for the first time ever in a major international tournament.
Ronaldo's efforts included four unsuccessful free kicks, which also included a brilliant save by Oblak in the 89th minute.
Roberto Martinez's star-studded Portugal side displayed impressive defence and some fine flashes of attacking football in the game.
Costa's fine goalkeeping helped Ronaldo earn redemption as he pulled out some fine saves to set a semifinal clash with Kylian
France secured a hard-fought 1-0 win over Belgium, securing their quarterfinal spot with the help of a Randel Kolo Muani's strike in the 85th minute. His strike deflected off defender Jan Vertonghen and went past the goalie Koen Casteels to seal the victory.
France controlled the ball possession for the majority of the game and almost broke the deadlock at the either side of the half-time with Marcus Thuram and Aurelien Tchouameni while Mbappe also delivered some fantastic footwork. But Mbappe's finishing was off-colour.
Belgium could have secured a victory as Romelu Lukaku and Kevin De Bruyne tried to score, forcing saves from Mike Maignan.