Colin Greening had a goal and an assist while Ben Bishop made 25 saves for the Senators, who had dropped their previous two.
"I thought we had a real good start to the game and they responded well," said Ottawa head coach Paul MacLean. "But we responded to their surge and I thought that showed some of the character we have on this team."
Tim Wallace, Ryan Shannon and Steven Stamkos all scored for the Lightning, who had won their past four games.
"Another episode of the same show," said Tampa Bay head coach Guy Boucher. "It's been that way since summer. One of those years that you have to battle through."
Mathieu Garon left the game early in the first period with a lower body injury after stopping all three shots he faced. Dwayne Roloson allowed five goals on 30 shots in relief.
The Senators hold the seventh spot in the Eastern Conference with 78 points, one back of New Jersey, while the Lightning are four points back of Winnipeg for the eighth spot with Washington in front of them.
Ottawa scored three times in the first period to take control of the game.
The first came from Sergei Gonchar as he redirected a Greening pass from the low left side 9:38 in.
It was 2-0 with 2:23 left in the frame when Greening one-timed the puck home from the slot and Kyle Turris scored 53 seconds later on a wrister from the slot.
Tampa got back into the game with a pair of goals after Shannon scored on a one-timer off a Tom Pyatt pass 1:24 into the middle stanza. Wallace made it a one-goal game six minutes later on a heavy wrister from the left circle.
Erik Karlsson, though, made it a two-goal game once again when his shot from the right circle found the back of the net for a power-play marker.
Stamkos' league-leading 48th goal of the season came 5:41 into the third on the power play as he got a pass from Teddy Purcell near the right circle and beat Bishop to the short side.
Michalek gave his team some breathing room on the power play with 7:48 to play as his one-timer from the inside left circle found the back of the net and he completed the natural hat trick with a pair of empty-net goals to bloat the final score.
Michalek's only other hat trick came on October 15, 2009, also against Tampa Bay...Ottawa hosts the Rangers on Thursday...Tampa plays in Washington on Thursday...Ottawa swept the season series with Tampa Bay...The Lightning were 1-for-3 on the power play while the Senators were 2-for-3.