Dallas surged to a 3-0 first-period lead on two man-advantage goals from Boucher and one from defenceman Sergei Zubov. Eric Lindros assisted on all three. The Stars, 5-2 in their last seven games, went 3-for-5 on the power play in the first period.
Seven of the goals came on the power play, including two by Dustin Brown of the Kings, who are 2-4-1 in their last seven games.
Jere Lehtinen added an empty-net goal for Dallas with 25 seconds left to make it 5-3.
Alexander Frolov of the Kings crashed the net and capitalized on a two-man advantage with his 13th goal of the season at 8:17 of the final period to narrow the deficit to 4-3.
Rookie goalie Mike Smith stopped 22 shots for the Stars. Smith was playing in his third straight game and making his second consecutive start in place of Marty Turco. Coach Dave Tippett said Turco isn't in danger of losing his spot as the team's top goaltender, but Tippett wanted to see how Smith responded to consecutive starts.
Smith relieved Turco in the first period of Monday night's 5-4 victory over Colorado, then Smith got his second career shutout in a 1-0 win over Nashville on Wednesday night.
Dallas has won all four of its games against Los Angeles this season.
Boucher's first goal glanced in off the stick of a Kings' defender at 4:30 of the opening period to get the scoring under way.
Zubov made it 2-0 at 12:53 of the opening period with a one-timer from 40 feet while the Stars held a two-man advantage, and 26 seconds later Boucher beat Kings goalie Mathieu Garon from beyond the right circle to stretch the lead to 3-0.
But Brown scored his man-advantage goals over a span of 2:21 in the second period to pull Los Angeles within 3-2.
Brown's first goal at 5:48 snapped Smith's shutout streak of 105 minutes, seven seconds.
Boucher's third goal of the night and sixth of the season came on a blast from just inside the blue line at 11:00 of the second period to push Dallas' advantage to 4-2. Fans littered the ice with hats to mark the Stars' first hat trick of the season.
Notes: Smith improved his record to 5-1. ... Mike Modano's assist on Boucher's second goal was his 1,200th NHL point. Modano is the 42nd player in NHL history to reach the milestone. ... Lehtinen was back in the lineup after missing four straight games with a leg injury. ... Stars captain Brenden Morrow also returned after sitting out one game with a groin injury, but reinjured the groin in the first period and did not return.