Patrick Marleau and Logan Couture also scored as part of San Jose's reconfigured second line and the Sharks moved within one win of advancing to the Western Conference final for the fourth time in franchise history.
San Jose will look to secure a spot in its first conference final since 2011 by winning at Nashville in Game 6 on Monday night.
Melker Karlsson added a late goal and Martin Jones made 24 saves to give the home team its fifth straight win in this series.
Game 4 overtime hero Mike Fisher scored and Pekka Rinne made 23 saves, but Nashville allowed goals in the opening and closing minutes of the second period.
The Predators now must try to repeat the trick they pulled off in the first round against Anaheim by rallying from a 3-2 series deficit if they want to reach the conference final for the first time in franchise history.
San Jose coach Peter DeBoer's decision to move Marleau from third-line center to second-line wing on Couture's line paid big dividends. Marleau opened the scoring midway through the first and Couture delivered big plays to start and finish the second period.
On the opening shift of the second period, Couture took a pass from Joonas Donskoi and skated in on a breakaway where stickhandled in and slid the puck between Rinne's pads to put San Jose up 3-1 just 35 seconds into the period.
Couture then drew a tripping penalty from Roman Josi in the final minute of the period. The Sharks then scored right off the faceoff with Marleau setting up Pavelski on a one-timer for his second goal of the game.
The Sharks killed an early power play in the third period and limited Nashville's chances after that to seal the win.
The new second line wasn't the only lineup switch DeBoer made. He also gave Dainius Zubrus his first playoff action on the fourth line in place of Tommy Wingels. Zubrus brought a physical element to the game but it was Couture's line that did most of the damage.
Donskoi had two assists, including a nifty backhand pass right to Marleau for a one-timer that opened the scoring midway through the first.
The Predators answered with a familiar line when Fisher completed a tic-tac-toe passing sequence from James Neal and Colin Wilson to tie it with his third goal in the past two games. That line scored all four goals for Nashville in the Game 4 win, including Fisher's goal in triple overtime to end the game after 51:12 of overtime.
But San Jose answered right back with a goal from its top line when Joe Thornton sent a blind, backhand pass to Pavelski in the edge of the circle for a one-timer that beat Rinne late in the period.
NOTES: Pavelski has seven career multigoal playoff games, including the opener in round one against Los Angeles. ... San Jose has not had a playoff hat trick since Devin Setoguchi against Detroit in 2011. ... F Mike Ribeiro returned to the lineup after being scratched the past two games for Nashville.
Click here for more stories on the San Jose Sharks.