Mexico, meanwhile, failed to impose the high-tempo rhythm which had floored Germany and once Ludwig Augustinsson put Sweden ahead with a somewhat fortuitous goal five minutes after halftime, there was no way back.
VAR came into play in stoppage time after an offside decision overruling a Jang Hyun-Soo goal from a corner, was review by the referee and overturned, giving the Koreans a deserved lead.
They will now face the winners of Group E in Samara on July 2, while Sweden will play the runners-up the following day in St Petersburg.
Mexico survived a nail-biting scare to advance to the World Cup's round of 16 as defender champion Germany was stunningly dumped out of the tournament on Wednesday.
While celebrations were muted among the players, there can be no doubt that the relief for them - and the team's millions of supporters - was enormous.
Porsche beats 35-year-old Nurburgring lap record
What's remarkable about this particular record attempt is that it took all of one hour to break the outright Nurburgring lap time. The hybrid system captures energy from the front brakes and the exhaust system, storing it in a lithium-ion battery.
Jesus Gallardo was shown the quickest yellow card in World Cup history for a late challenge on Ola Toivonen after just 15 seconds, but the Mexico left-back cleared the resultant free-kick after Berg's knockdown fell just out of Granqvist's reach.
"My feelings in the last few minutes, my feelings in general, were that I wasn't too happy with the way we defended at all".
For Granqvist it was his second goal from the spot in the tournament, after he also scored on a penalty kick against South Korea.
It could have been worse for Mexico, who started badly and never recovered, and Sweden were denied what looked a strong call for a penalty on 30 minutes.
Tonight's Group G matches will decide who Sweden and Mexico will play in the Round-of-16.
"We qualified because we beat Germany and Korea but nevertheless I am very hurt", he said.
Maryland newspaper office shooting victims identified
Police said earlier reports about the suspect mutilating his fingers in an attempt to alter his fingerprints are not confirmed. Video taken at the scene captured dozens of people fleeing the newspaper's building, hands raised above their heads.
The Mexicans were a shadow of the team that had beaten Germany and South Korea and had pundits speaking of them as potential world champions.
El Tri's faithful could be seen frantically checking their phones for scoring updates from Germany's game soon after Sweden's second goal.
Mexico has lost in the round of 16 for the past six World Cups in a row.
The four-time champions allowed a pair of injury-time goals while knowing a 1-0 victory would have been enough to advance because of the result in the other group match.
But the Mexicans also threatened several times to score.
Janne Andersson has once again criticised Germany for the "scornful" celebrations that followed their late victor against his Sweden team last weekend. "We haven't forgotten hearing the boos at the Azteca, and that has strengthened us mentally", Ochoa said.
House overwhelmingly rejects immigration bill despite Trump's call to pass it
Democrats, though, said the bill would have made that path more hard . "This only works if Trump's behind us", one member said. Democrats denounced it as "anti-immigrant", voting against it along with 112 Republicans who felt it was insufficiently tough.
Hernandez needs one goal to make him Mexico's all-time leading scorer in World Cup play with five.