Joonas Donskoi, Tomas Hertl and Joe Thornton scored, and Martin Jones made 22 saves for the Sharks (24-13-7), who are 5-1-0 in their past six games and 10-2-2 in their past 14.
Karlsson extended his personal point streak to 13 games (one goal, 21 assists). He had 10 assists in eight games before serving a two-game suspension for an illegal check to the head of Kings forward Austin Wagner on Dec. 22. He has a goal and 11 assists in five games since returning.
"I think the two points is the big part," Karlsson said when asked about his streak. "I think that we've come together as a team and we're playing better and better as the season gets long. That's all that matters, as long as you win games. Everybody's contributing, whatever you do out there, and I think that's been the mindset in here with the entire group, that it doesn't really matter who does it, as long as someone does it and everybody does it together."
[WATCH: All Kings vs. Sharks highlights]
Anze Kopitar scored, and Jack Campbell made 26 saves for Los Angeles (17-24-3). It was Campbell's second start in four games after missing the previous 24 games with a knee injury.
"I thought we battled," Campbell said. "We played a good game and deserved to win. I needed to make the save on the second goal."
The Sharks were coming off a 5-2 victory against the Tampa Bay Lightning on Saturday when they ended the Lightning's 16-game point streak.
"We had an emotional win the other night, and you always wonder how you're going to come back," San Jose coach Peter DeBoer said. "I think playing L.A. helped with that because we know it's going to be a hard game and you have to show up and play a man's game against them in order to have some success. I thought we did a good job tonight.
"I was a little concerned because we had some chances to extend the lead, a couple empty nets and some good opportunities to really get out in front and we missed them and let them hang around a little bit. But that was the only thing I was concerned about."
Video: LAK@SJS: Donskoi puts home rebound for opening goal
Donskoi gave San Jose a 1-0 lead at 17:43 of the first period when he knocked in the rebound of an Evander Kane shot. Karlsson's fluttering pass bounced off Kings forward Dustin Brown's skates to Kane in the left face-off circle. Campbell stopped Kane's shot but couldn't control the rebound, and Donskoi scored with a wrist shot from close range.
The Kings tied it 1-1 at 3:42 of the second period when Kopitar scored from in front of the crease on a give-and-go with Brown.
Hertl put San Jose ahead 2-1 at 9:09 of the second, taking a long lead pass from Karlsson and scoring on a backhand from the right circle to the short side. Jones had an assist, his first in 222 games with San Jose and third of his career.
"He picks a great route and I just have to wait for him to break free a bit, and he does the rest," Karlsson said. "That's what it's all about. I think we're starting to figure each other out out there. It's nice to see when guys take advantage of their scoring chances that we got. There weren't too many out there today."
Video: LAK@SJS: Karlsson, Hertl connect for sweet goal
Thornton scored an empty-net, power-play goal with 21 seconds remaining to make it 3-1.
The Kings were coming off a 4-0 win against the Edmonton Oilers on Saturday but lost for the third time in four games.
"We need two, three goals every night to win," Los Angeles defenseman Drew Doughty said. "We can't get four one night and one the next."
The Sharks were without injured defensemen Marc-Edouard Vlasic (wrist) and Justin Braun (knee), but defenseman Radim Simek returned after missing two games with a concussion.
They said it
"It's the San Jose Sharks and the Los Angeles Kings. It's a rivalry game, and as much as we respect them, we hate them. We're chasing them trying to get back to a [Stanley Cup] Playoff spot. Emotions run high and sometimes it gets chippy. I love a chippy game." -- Kings defenseman Drew Doughty
"We played pretty well the last couple, especially in the third period with leads. It's pretty encouraging the way we played, and hopefully we can just keep it rolling here." -- Sharks goalie Martin Jones
Need to know
Karlsson is one of six defensemen in NHL history with at least one assist in 13 straight games he played in (Paul Coffey, 17 games, 1985-86; Brian Leetch, 15, 1991-92; Bobby Orr, 14, 1970-71; Phil Housley, 14, 1992-93; Denis Potvin, 13, 1983-84), according to NHL Public Relations. ... Karlsson is the first NHL defenseman with at least one point in 13 consecutive games since Shayne Gostisbehere of the Philadelphia Flyers did so in 15 straight from Jan. 19-Feb. 20, 2016. ... Brown had an assist on Kopitar's goal and has five points (one goal, four assists) in the past five games. ... The Kings did not have a power play for the second game this season. ... Sharks forward Melker Karlsson played his 300th NHL game. ... Kane extended his point streak to five games (three goals, four assists).
Kings: Host the Ottawa Senators on Thursday (10:30 p.m. ET; FS-W, TSN5, RDS, NHL.TV)
Sharks: Host the Edmonton Oilers on Tuesday (10:30 p.m. ET; NBCSCA, SNW, NHL.TV)
Video: Donskoi, Hertl, Karlsson propel Sharks past Kings