Brent Burns had two assists for San Jose (24-27-4), which has won two games in a row. Aaron Dell made 28 saves.
The Sharks scored five straight goals after falling behind by two in the opening 5:20.
"It was a little bit of a rough start," said San Jose defenseman Erik Karlsson, who had an assist. "They obviously came out with the fresher legs and more intensity. I thought we stuck with it and kept it tight, and after the first six or seven minutes, we controlled most of the game and we played a smart game."
WATCH: [All Sharks vs. Oilers highlights]
Connor McDavid scored for Edmonton (28-20-6), which has lost two games in a row. Mikko Koskinen allowed six goals on 31 shots.
"Even though we were up two, I thought they were still taking the play to us," McDavid said. "We got a couple, which was good, but they took the game to us all night. We were just flat and emotionless. We're at our best when we're playing with emotion and being physical and in guys faces and playing the right way."
Sam Gagner scored on a backhand from the slot at 4:04 of the first period to give the Oilers a 1-0 lead.
McDavid made it 2-0 at 5:20 when he skated past defenseman Mario Ferraro on the left side on the rush and lifted a shot over Dell.
"We knew there was plenty of time left," Meier said. "McDavid, we all know his skill and that he was going to make a play and he's going to beat a guy wide. We just stuck with it, we didn't panic, we stayed positive, and that's what we have to do in those moments. We found a way to turn the game around and came out on top."