Yarmolenko had been granted compassionate leave after Russia's invasion of Ukraine and missed West Ham's 1-0 loss in the first leg in Spain due to illness.
He reacted sharply to a rebound, however, to send the London club into a European quarterfinal for the first time since 1981 and knock out Sevilla, the record six-times winners of the competition.
Yarmolenko gave his shirt to a fan with a Ukraine flag as he celebrated a win that started when Tomas Soucek headed in Michail Antonio's cross at the far post to put West Ham in front five minutes before half-time.
West Ham manager David Moyes said he hoped the goal would lift Yarmolenko.
"We've all been there where you're losing and you think there's no chance that we're going to get a result," Moyes told BT Sport.
"In football things change for you. So I hope maybe this changes a little bit of what's in Yarmo's head, maybe what's happening in life.
"But overall, if he's getting mentioned worldwide and then everybody else is realising the damage Russia is doing to Ukraine."
The teams finished deadlocked at 1-1 on aggregate after 90 minutes before Yarmolenko netted the winner for the Premier League side.
"Unbelievable! This season is like a dream come true," Antonio told BT Sport. "Yarmolenko is such a lovely guy. I can't imagine what he's going through. He's got a finishing touch now. Hopefully, he can keep doing it."
It was the second extra-time loss on the night for the two Seville teams trying to reach the final in their home city.
Lyon held Porto to a 1-1 draw and also advanced to the last eight 2-1 on aggregate.