Detroit had spent the final 3:46 of regulation and first 1:14 of overtime a man down after David Legwand was given a major and game misconduct for a butt ending call against Evgeni Malkin, but the team killed it off to keep the game going.
With time winding down, a turnover in the Detroit end saw the Red Wings go the other way on a 3-on-1. Skating down the right wing, Alfredsson let fly with a shot that Marc-Andre Fleury stopped, but the rebound came out front, went off Pittsburgh's Rob Scuderi and made it into the net just before the final buzzer.
Alfredsson scored twice and added an assist, while Gustav Nyquist, Tomas Tatar and Todd Bertuzzi scored for the Red Wings, who have won three of their last four games. Jimmy Howard gave up four goals on 43 shots in the win.