Colin Greening scored 25 seconds into the second, and Zenon Konopka netted the Senators' fifth goal of the period with 5.7 seconds left, increasing Ottawa's lead to 5-3 just 4 seconds into a power play.
"We got a big goal from Z on a play right at the end of the period, then we come in feeling good about ourselves," Spezza said. "It was good to have that break to talk about how we wanted to play against these guys with the lead."
Karlsson recorded his 100th point with his third assist of the period on Konopka's goal.
Pittsburgh's Steve Sullivan had a goal and two assists as the teams combined for eight goals in the middle period after a scoreless first. Matt Niskanen and Evgeni Malkin scored power-play goals 1:07 apart to draw the Penguins even at 3.
Penguins captain Sidney Crosby missed his fourth straight game because of a recurrence of concussion-like symptoms. He is out indefinitely, and the Penguins are 1-3 since he was sidelined again.
"Typically, we're a lot better defensively than that," Penguins forward Craig Adams said. "Whether it's defensive zone coverage or plays up the ice and getting caught on rushes and things like that, certainly our details away from the puck weren't very good."
Alex Auld stopped 32 shots for Ottawa in a matchup of backup goalies.
Pittsburgh's Brent Johnson made 14 saves through the first two periods and then was replaced by Marc-Andre Fleury, who allowed Spezza's second goal of the game 12:23 into the third. Fleury finished with four saves.
Cowen scored the seventh goal of the second, 13:20 into the period, to put Ottawa up 4-3.
"We did a lot of good things offensively," Alfredsson said. "They scored two quick power-play goals on two chances there which were questionable calls. That was tough, but we got a fourth one right after -- and that's huge -- to get our momentum back."
Konopka made it a two-goal lead with his third goal, scoring off the faceoff after Alexandre Picard's high-sticking penalty with 10 seconds left.
Sullivan drew Pittsburgh even at 1 with his sixth goal at 1:35.
Spezza scored his 11th to give Ottawa a 2-1 lead as the teams combined for three goals in the first 2:04.
Alfredsson made it 3-1 at 6:45 when he scored for the second game in a row.
The Penguins needed a total of 15 seconds of power-play time to get even.
Niskanen made it 3-2 at 11:07 with a slap shot past Auld from the left point 7 seconds after Chris Neil was called for hooking.
Malkin needed 8 seconds after Alfredsson was sent off for high-sticking to convert the Penguins' next opportunity with the man advantage at 12:14.
Johnson took Karlsson's slap shot off his mask 20 seconds into the game. ... Senators LW Milan Michalek missed his second game because of a concussion.
Copyright by STATS LLC and The Associated Press
Arena: Canadian Tire Centre Location: Ottawa, Ontario
Referees: Tom Kowal, Chris Lee Linesmen: David Brisebois, Greg Devorski
Attendance: 19,710 (106.5% full)
Team Stat Comparison
Power Play Goals
Power Play Opportunities
Shots on Goal
No scoring this period
Colin Greening (8)
Assists: Jason Spezza, Jared Cowen
Steve Sullivan (6)
Assists: Arron Asham, Joe Vitale
Jason Spezza (11)
Assists: Daniel Alfredsson, Erik Karlsson
Daniel Alfredsson (9)
Assists: Jason Spezza, Brian Lee
Matt Niskanen (2)
(Power Play) Assists: Steve Sullivan, Chris Kunitz
Evgeni Malkin (12)
(Power Play) Assists: Steve Sullivan, James Neal
Jared Cowen (4)
Assists: Nick Foligno, Erik Karlsson
Zenon Konopka (3)
(Power Play) Assists: Erik Karlsson, Jared Cowen
Jason Spezza (12)
Assists: Daniel Alfredsson, Jared Cowen
Chris Kunitz (10)
Assists: Simon Despres, Evgeni Malkin