VANCOUVER -- Markus Granlund scored with 6:21 remaining, and the Vancouver Canucks rallied for a 4-2 win against the San Jose Sharks at Rogers Arena on Tuesday.
Tanner Pearson scored twice for Vancouver (35-35-10), including the game-tying goal with 8:42 left in the third period.
"To be down a goal going into the third period and come back and take the victory was a big positive," Pearson said. "Especially playing these playoff teams, teams that are saddling up to go to the playoffs, they're playing their best hockey, or want to anyway. If we can withstand that and beat some teams, it could carry some momentum into next year."
[WATCH: All Sharks vs. Canucks highlights]
Thatcher Demko made 33 saves for the Canucks, who have won three straight games but were eliminated from Stanley Cup Playoff contention last Friday.
"He was dialed in," Vancouver coach Travis Green said of Demko. "It might have been his best game."
Joe Pavelski scored in his return after missing seven games because of a lower-body injury for San Jose (44-27-9), which has one win in its past 10 games (1-8-1).
"It was nice to give me a little confidence," Pavelski said. "But at the end of the day, it's not how you feel; it's about the wins, and we have a little way to go."
Video: SJS@VAN: Pavelski nets PPG, Thornton ties Yzerman
The Sharks clinched second place in the Pacific Division and will have home-ice advantage in the Western Conference First Round against the Vegas Golden Knights. San Jose has two games left in the regular season to build some positive momentum for the playoffs.
"We've got two kind of practice shots at this again and then the real season starts, so hopefully we can put it together and then get ready for Vegas," Sharks center Joe Thornton said. "But I think we can get out of this, no problem."
Thornton had two assists to tie Steve Yzerman (1,063) for eighth place on the NHL all-time list in his 1,564th game, which tied Nicklas Lidstrom for 12th all-time.
"That's the reason I wear No. 19," Thornton said of tying Yzerman. "It's pretty cool."
Martin Jones made 19 saves for San Jose, which has allowed 43 goals in its past 10 games.
"It's been a little bit of everything," Jones said. "We've had some tough bounces, probably too much stuff off the rush. We need to work for each other coming back into our own end and be able to trust we are going to be there for each other, and then we need some more saves."
Pearson scored on the Canucks' first shot 1:28 into the game after a backhand pass from Bo Horvat below the goal line into the slot for a 1-0 lead.
Video: SJS@VAN: Horvat, Pearson combine for early tally
Kevin Labanc tied it 1-1 at 5:09 when he redirected Brenden Dillon's shot from the point after a pass from behind the net by Thornton.
Pavelski's power-play goal at 10:47 gave the Sharks a 2-1 lead. Thornton passed out of the left corner to Tomas Hertl at the top of the crease, and his missed one-timer went across to Pavelski for his team-leading 38th goal.
"Nice to get on the power play and find a puck that slides over with an open net," Pavelski said.
Pearson tied it after Jones saved Loui Eriksson's breakaway, jamming in a loose puck before Jones could cover. The Sharks challenged for goaltender interference and Jones argued he had the puck under his glove, but the call stood.
Video: SJS@VAN: Pearson jams puck past Jones to tie game
"That's why we challenged it," San Jose coach Peter DeBoer said. "But they had a view they said where the puck was never covered. We didn't have that camera view. I'd like to see it."
Granlund put the Canucks ahead after a deflection bounced behind Jones, and Troy Stecher scored a shorthanded goal into an empty net with 1:30 left for the 4-2 final.
"We were in control of that game until the last 10 minutes," DeBoer said. "We've got to find a way to win, though."
They said it
"I'm trying to figure out how you lose that game, but that's the way it's going right now." -- Sharks captain Joe Pavelski
"You want a team that competes. You want a team that wants to win. People come to the game to watch your team play hard and try. These are not easy games; we're playing good hockey teams. So that's what you want as a coach, and I thought tonight was a really good example of it." -- Canucks coach Travis Green
Need to know
Sharks defenseman Erik Karlsson missed his 16th straight game with a groin injury, but he participated in warmups and said earlier Tuesday he will be ready for the start of the playoffs next week. … Labanc has six points (three goals, three assists) in a six-game point streak. … Horvat has 12 points (four goals, eight assists) in his past 12 games.
Sharks: At the Edmonton Oilers on Thursday (9 p.m. ET; SNW, NBCSCA+, NHL.TV)
Canucks: At the Nashville Predators on Thursday (8 p.m. ET; FS-TN, SNP, NHL.TV)
Video: Pearson, Granlund propel Canucks past Sharks, 4-2