WASHINGTON -- Alex Ovechkin had a hat trick, but Tomas Hertl scored his third goal of the game for the San Jose Sharks 1:48 into overtime to hand the Washington Capitals their sixth straight loss, 7-6 at Capital One Arena on Tuesday.
Evander Kane sent the game to overtime by tying it 6-6 with one second left in the third period. Joe Pavelski threw the puck in front, and Kane knocked in the puck at the side of the net for his second goal of the game.
[WATCH: All Sharks vs. Capitals highlights]
"I thought the game was over," San Jose center Logan Couture said. "I came to the bench and I changed and I was frustrated. I broke my stick over the bench, then I look up and [Kane is] putting the puck in the net. Pretty wild to be able to tie that up there."
Video: Enterprise Hat Trick: Hertl caps off hat trick in OT
Ovechkin (643) had an assist and passed Dave Andreychuk (640) for sole possession of 14th place on the NHL goals list. He needs one point to tie Sergei Fedorov (1,179) for the most points by a Russia-born player in NHL history.
Hertl had an assist, and Pavelski had a goal and three assists for San Jose (29-16-7), which had lost three straight. Couture had a goal and two assists, and Martin Jones made 33 saves for the Sharks, who have given up six goals in each of their past four games.
"That was a wild one," San Jose coach Peter DeBoer said. "It was like the All-Star Game five days early. The East Coast version of the All-Star Game. I don't know what even to say. We'll take it. We needed it."
T.J. Oshie had a goal and two assists, and Evgeny Kuznetsov had a goal and an assist for Washington (27-16-6). Andre Burakovsky scored, and Braden Holtby made 36 saves.
Video: Enterprise Hat Trick: Ovechkin's 23rd career hatty
"That was not Washington Capital hockey," Capitals coach Todd Reirden said. "Going chance for chance against a team that has that type of firepower, that's not going to win in the long run. We learned a hard lesson again on that tonight because that's not acceptable and that's not going to work in the long run. No way."
With 20 seconds left in the third, Ovechkin attempted to shoot the puck down the ice rather than pass, and San Jose defenseman Brent Burns intercepted it.
"It was my mistake at the end of the game," Ovechkin said. "I tried to make a rush play. Have to be better in this situation."
The Sharks took a 1-0 lead 12 seconds into the game when Pavelski put in a loose puck for his 27th goal.
Ovechkin tied it 1-1 when he scored on a rebound during a power play at 10:41.
Video: Clutch Performance: Kane tallies two goals in OT win
The Capitals took a 2-1 lead at 12:11 when Burakovsky scored from the left face-off circle.
San Jose made it 2-2 when Hertl converted a pass from Pavelski on the power play at 14:27, but Oshie's goal at 15:19 off an Ovechkin feed put Washington in front 3-2.
Kane scored on a rebound 52 seconds into the second period to tie it 3-3.
Kuznetsov made it 4-3 when he scored off a rebound at 2:53, and Ovechkin's second goal made it 5-3 at 5:41.
San Jose pulled within 5-4 on Couture's breakaway goal at 14:39.
Ovechkin completed the hat trick with a one-timer on the rush to make it 6-4 at 5:52 of the third period.
Hertl pulled the Sharks within 6-5 at 10:02.
Video: SJS@WSH: Ovechkin, Oshie team up for pretty goal
They said it
"I'm just happy I got the game-winner and we won the game. It was a crazy game, but everybody pushed hard, we stayed with it and we got it done. That's what matters." -- Sharks center Tomas Hertl
"I think we're just not all the way there right now. It seems like in a lot of instances, we're like 90, 95 percent all-in, and that extra 5 or 10 percent that we don't bring, right now they're ending up in goals against." -- Capitals forward T.J. Oshie
Need to know
It was Ovechkin's third hat trick of the season and the 23rd of his NHL career. He leads the NHL with 36 goals. … Brendan Shanahan is 13th on the NHL all-time goals list with 656. … Reirden said Ovechkin will play at the Toronto Maple Leafs on Wednesday and sit out when the Capitals host the Calgary Flames on Feb. 1 to satisfy his penalty for missing the 2019 Honda NHL All-Star Game, which is in San Jose on Saturday. … This is Washington's longest losing streak since it lost seven straight from Jan. 12-24, 2014. … The Capitals have allowed at least seven goals in three of their past four games. … The Sharks were without all-star defenseman Erik Karlsson for the third consecutive game because of a lower-body injury. Karlsson was scheduled to have tests in California on Tuesday, and his status is unclear for the All-Star Game. … San Jose is off until Feb. 2; it will have its mandatory five-day break after the All-Star Game.
Sharks: Host the Arizona Coyotes on Feb. 2 (10:30 p.m. ET; NBCSCA, FS-A PLUS, NHL.TV)
Capitals: At the Toronto Maple Leafs on Wednesday (7:30 p.m. ET; NBCSN, SN, SN360, TVAS)
Video: Hertl nets hat trick, OT winner in 7-6 win vs. Caps