Before the game, Klose was presented with a special picture for winning his 100th cap during the 2010 FIFA World Cup™ and he capped his 103rd appearance with two goals to leave him as joint second Germany goal-scorer of all time.
His goals in injury time at the end of both halves out him alongside Joachim Streich, but 12 behind Germany's all-time record scorer Gerd Mueller.
The win at Cologne's Rhein Energie Stadion gives Joachim Low's Germany six points from their first two games, after their 1-0 win over Belgium on Friday.
The game got off to a bruising start when Germany centre-back Per Mertesacker took an elbow in the face, leaving him with a bloody face, and he was replaced by Westermann after ten minutes.
With Germany attacking in waves it was only a matter of time before the home side got the breakthrough they were pushing for and it came on 28 minutes when Mertesacker's replacement Westermann tapped in.
Azerbaijan striker Vugar Nadyrov tested Germany goalkeeper Manuel Neuer on 36 minutes with a long-range shot, but as the visitors started tiring Germany extended their lead with two goals in added time at the end of the first-half.
Podolski scored after taking a return pass from Real Madrid's Mesut Ozil, driving his shot past goalkeeper Kamran Agayev on 46 minutes.
And Podolski then turned goal provider when he took a pass from centre-back Badstuber and squared the ball for Klose to tap the ball past Nadyrov to make it 3-0 at the break.
Things got worse for Azerbaijan when Sadygov turned the ball into his own net on 53 minutes, but the visitors pulled a goal back when Neuer made a rare mistake on 57 minutes - striker Vagif Dzavadov curled in a corner and Neuer allowed the ball to bounce off his chest into the back of the net.
Badstuber took advantage of some sloppy defending to score after 86 minutes before some deft footwork from replacement Cacau allowed Klose a simple tap-in from close range to seal the win.