Arturo Vidal scored twice, including a penalty, and Fernando Llorente and Paul Pogba were also on target for the hosts.
Andrea Barzagli's own goal gave the visitors hope and lively on-loan Juventus striker Gabbiadini was also on target for Sampdoria.
However, Juve picked up the three points to maintain their eight-point advantage at the top over Roma, who beat Livorno earlier in the day.
After Carlos Tevez had shot over, Juve took an 18th-minute lead when Pogba found Vidal inside the box - and the Chilean slotted low into the corner of the net.
Gabbiadini hit the post before Llorente powerfully headed Juve 2-0 ahead in the 24th minute from a corner.
Gianluigi Buffon saved from Shkodram Mustafi, before Tevez struck the woodwork at the other end in an entertaining opening half.
The visitors were back in the contest seven minutes before the interval when Gabbiadini's low cross was turned into his own net by Barzagli - on his return from suspension.
However, Vidal made it 3-1 from the spot four minutes later, after Vasco Regini had been fouled inside the Sampdoria penalty box.
After Pogba had shot over, the visitors threatened through Pawel Wszolek - who failed to find the target - and Lorenzo De Silvestri, who was denied by a combination of Buffon and the woodwork.
Llorente wasted a chance and it looked as if it might prove costly when Gabbiadini tapped in to make it 3-2 after Buffon had failed to hold Regini's close-range header.
Gabbiadini struck the bar before Juve's nerves were eased by a fantastic goal from Pogba 12 minutes from time.
The former Manchester United man scored from outside the box with a curling effort - and three minutes from time he saw a left-foot shot skim a post.