Semyon Varlamov and the Colorado Avalanche had their eyes on a victory after tying the game at 2 with 3 minutes, 16 seconds to play in regulation. But after a scoreless overtime, the Sharks won the shootout 2-1 to win the game 3-2 on Tuesday night in San Jose, Calif.

Ben Margot/Associated Press

Semyon Varlamov and the Colorado Avalanche had their eyes on a victory after tying the game at 2 with 3 minutes, 16 seconds to play in regulation. But after a scoreless overtime, the Sharks won the shootout 2-1 to win the game 3-2 on Tuesday night in San Jose, Calif.

SAN JOSE, Calif. – Patrick Marleau scored in the fourth round of the shootout, Antti Niemi stopped three shots in the final session, and the San Jose Sharks showed signs of coming out of a monthlong slump with a 3-2 victory over the Colorado Avalanche on Tuesday night.

Michal Handzus made the first shot, and two Sharks missed before Marleau shook Semyon Varlamov, sneaking the puck between the goaltender’s legs for the winning score.

Niemi turned aside 25 of 27 shots before the shootout and tossed aside John Mitchell’s shootout attempt to send it to a fifth round.

Logan Couture and TJ Galiardi also scored goals for the Sharks, who snapped a two-game losing streak. San Jose has won eight in a row at home, including three in overtime.

San Jose had been 1-6-3 in its last 10 games since setting a franchise record by winning its first seven of the season. The Sharks’ 41 shots on goal were the most since a 4-0 win over the Avalanche exactly a month earlier.

Chuck Kobasew scored in the first period for the Avalanche, and Mark Olver tied it with 3 minutes, 16 seconds remaining in regulation.

Colorado fell to 0-1-2 on its three-game road trip.

San Jose overcame the loss of its key contributors, while Colorado struggled to put pressure on net.

Avalanche center Matt Duchene, leading the team with 11 assists and 17 points, sat out with a lower-body injury. Sharks forward Ryane Clowe served the second and final game of his suspension by the NHL for instigating a fight late in Friday’s 2-1 loss at Chicago, and San Jose placed defenseman Brent Burns on injured reserve with a lower-body injury.

The Sharks looked at home from the start, and Colorado never looked cozy – as usual. The Avalanche have lost eight in a row in San Jose since winning Game 1 of their first-round playoff series in 2010.

Just 25 seconds into the game, Joe Thornton stole the puck from the back boards and quickly passed to Couture collapsing on goal. Couture flicked the puck past Varlamov, falling to the ice as his seventh goal of the season – and first in nine games – sailed into the back of the net.

It was the fastest Sharks’ score this season, topping Thornton’s goal 43 seconds into a 4-1 win over Vancouver on Jan. 27. Protecting the lead only lasted a little longer.

Sharks Jose couldn’t clear the puck, and Kobasew corralled the rebound for the tying score with about 8 minutes remaining in the first period. It was Kobasew’s second goal of the season.

Another fast start after the break put the Sharks in control again.

James Sheppard flicked a blind, backhand pass to Galiardi just outside the far-post crease. Galiardi pushed the puck into the net for his first goal of the season, giving San Jose a 2-1 lead just 2:55 into the second period.

Michal Handsuz missed a chance for a short-handed goal that would’ve put the game away when a friendly bounce off the side boards gave him a breakaway, which Varlamov blocked with his body as a defender swooped in from behind.

Colorado capitalized just after its power play ended.

Jan Hejda’s slap shot deflected off the back board and into a crowd near the crease. Olver flipped the puck just over Niemi’s leg pads for the tying score.

A lack of offense has been a big part of San Jose’s slide.

The Sharks finished 0-for-5 on the power play, including a chance between the third period and overtime when Sharks forward Jamie McGinn was called for a high stick. In the last 10 games, they are 2-for-46 on the power play.

The Sharks have been held to two goals or fewer in 10 of their 11 games this month that didn’t go to a shootout.

Avalanche Crumblings

Avalanche captain Gabriel Landeskog returned to the arena one month to the day he got a concussion on a huge hit from Sharks defenseman Brad Stuart. Landeskog had been out of the lineup until the previous two games. ... The Sharks recalled D Matt Irwin from Worcester of the American Hockey League. ... Colorado will return home to face Calgary on Thursday, while San Jose hosts Detroit on Thursday.