Andersen and the Pacific Division leaders barely held off the Kings, who had a 38-20 shots advantage. An apparent tying goal by Anze Kopitar was waved off with 6:23 left because of incidental contact with Andersen, prompting Kings fans to litter the ice with debris.
Tim Jackman scored an early goal for the Ducks, who have won two straight after a four-game skid knocked them from their longtime perch atop the overall NHL standings.
Tyler Toffoli scored a power-play goal and Martin Jones stopped 18 shots for the Kings, whose eight-game winning streak was snapped Thursday by Toronto.
Los Angeles had won each of Anaheim's last five visits to Staples Center since November 2011. The late-game controversy added to the lively rivalry in the Southern California clubs' first meeting since their outdoor game at Dodger Stadium on Jan. 25.
Kopitar's shot through traffic hit Andersen's crossbar and apparently rattled in, but the officials immediately waved off any goal, later claiming Andersen had been hit. Replays showed the puck barely crossed the goal line while Marian Gaborik and Anaheim's Jakob Silfverberg were next to Andersen.
Dozens of fans threw drinks, water bottles and concession items on the ice, prompting a short pause in play while employees with snow shovels removed the garbage.
Andersen faced 29 shots in the first two periods during the second straight win for the Ducks, who snapped their skid with a victory at Colorado on Friday night.
The Kings scratched captain Dustin Brown, who played sparingly against Toronto on Thursday after coach Darryl Sutter said Brown's entire line looked tired. The U.S. Olympian missed practice Friday with what Sutter said was an illness.
Jackman put the Ducks ahead late in the first period with his fourth goal of the season, coming out of the corner to score on a slick pass from Mathieu Perreault. The fourth-line grinder has two goals in three games.
The Kings evened it on a power-play goal midway through the second period when Jarret Stoll's shot hit Andersen's pads and went straight to Toffoli for just his second goal in 26 games since Dec. 19.
Los Angeles hadn't scored against Anaheim in more than 148 consecutive minutes, going scoreless against their rivals since Kopitar's first-period goal early in their last meeting at Honda Center, two days before Jonas Hiller's shutout in Chavez Ravine.
Maroon put the Ducks back ahead on the game's next shot just 1:09 later. Sprawling Kings defenseman Jake Muzzin deflected the puck past Jones for Maroon's first goal since Jan. 30.
Anaheim scratched U.S. Olympic defenseman Cam Fowler, who incurred a lower-body injury Friday in Calgary. The Ducks also played without 43-year-old forward Teemu Selanne, who has sat out of the back end of several back-to-back sets this season.
NOTES: New Anaheim D Stephane Robidas took the pregame warmup, but didn't make his Ducks debut. The veteran blue-liner, acquired March 4 from Dallas, is nearly recovered from a broken leg. ... Jones started for the second time in three games after Jonathan Quick missed practice Friday with an illness. ... Anaheim's power play went 0 for 3, dropping to 2 for 42 in its last 13 games.