Senators (12) Daniel Alfredsson celebrates his goal with Chris Kelly (22) and Joe Corvo (7). (CP PHOTO/Fred Chartrand)
Daniel Alfredsson and Jason Spezza also scored for Ottawa (30-21-2), which was coming off a 3-1 loss in Montreal a night earlier. Alex Ovechkin and Donald Brashear replied for the Capitals (21-23-7), who have lost six of their past eight games.
Gerber was making just his sixth start for the Senators since Nov. 28 and first since Jan. 7, when he recorded a 6-1 win over the Philadelphia Flyers.
His 35 saves on Tuesday included 13 in the final period, when the Capitals pressed to tie the game in front of 19,178 at Scotiabank Place.
The closest they could get though was 3-2 after Brashear's second goal of the season at 3:02 of the third.
Olaf Kolzig made 35 saves in the Washington net.
Ovechkin extended his point-scoring streak to 12 games when he scored his 32nd goal of the season at 9:04 of the second period to pull the Capitals to within a goal at 2-1.
Heatley restored the two-goal advantage for the Senators after digging his own rebound loose and stuffing the puck past Kolzig on a power play at 16:31. The goal was the 31st of the season for Heatley who, leads Ottawa in scoring with 67 points.
The Senators finished the first period with a 2-0 lead on goals by Alfredsson at 9:04 and Spezza at 16:52. They could have had a third but Kolzig stopped Mike Comrie on a breakaway just prior to the Spezza goal.
Alfredsson scored his 18th of the season on a soft shot that went through the legs of Kolzig along the ice. As soon as the puck went in, Kolzig shook his head in disgust.
Spezza scored his 20th of the season and first since returning three games ago from a knee injury that cost him 14 games. He took a pass from Peter Schaefer off his skates at the side of the net and tucked the puck into an empty net.
Mike Fisher, who was playing his first game since missing the past 14 with a knee injury, also had an assist on the Spezza goal.
Notes: The Senators are off until Saturday, when they host the Toronto Maple Leafs . . . Washington plays the second game of its three-game game road trip in Florida against the Panthers on Thursday.