Khvicha Kvaratskhelia volleyed the hosts into the lead in the 42nd minute, before his ninth goal of the season was cancelled out by Federico Chiesa's late strike.
Chiesa must have thought he had done enough to rescue at least a point, only to see Raspadori score an 88th-minute winner after Wojciech Szczesny had saved Victor Osimhen's penalty.
Napoli moved up to seventh spot after claiming consecutive league victories for the first time since September, while Juventus remain in second position and 12 points adrift of Serie A leaders Inter Milan.
Napoli came into the match off the back of a confident-boosting 6-1 win over Sassuolo, but the reigning Serie A champions knew they faced a much tougher test against a pragmatic Juventus side.
Massimiliano Allegri's troops required just 10 minutes to carve out a clear-cut chance, with Dusan Vlahovic directing his header just wide from Chiesa's lofted cross.
Although the hosts took their time to grow into the contest, they finally created a meaningful opportunity in the 37th minute when Kvaratskhelia forced Szczesny into action following a purposeful run.
Undeterred, Kvaratskhelia ultimately found a way past Sczesny before the half-time break, with the Georgian latching onto Gleison Bremer's headed clearance to send a thunderous volley into the net.
After working hard to take the lead, Napoli were fortunate to take a slender lead into the break after Hamed Traore lost possession on the edge of the box, gifting Vlahovic the chance to take aim at goal.
However, the Serbia international could only whip his fizzing effort over the bar, leaving Allegri with work to do at the half-time interval.
Allegri's wise words appeared to have the desired effect as the visitors made a determined start to the second period.
Andrea Cambiaso blazed harmlessly over from inside the Napoli box, before Vlahovic fired straight at Alex Meret from a narrow angle.
Although they had to be patient, Juventus ultimately grabbed a deserved equaliser in the 82nd minute when Chiesa rifled a low strike into the bottom corner.
Just as momentum seemed to be in Juventus' favour, the gripping encounter provided one final dramatic twist after Joseph Ngonge was penalised for fouling Osimhen in the box.
The Nigeria international saw his subsequent penalty saved by Szczesny, but Raspdori reacted quickest to guide home the rebound.
Daniele Rugani spurned a glorious opportunity to net a stoppage-time equaliser, skying the ball from Kenan Yildiz's low cross to the relief of the home support.
Napoli interim boss Francesco Calzona has now avoided defeat in his opening four games in charge, and he will look to continue that run against Torino next weekend.
Meanwhile, Juventus will attempt to return to winning ways when they welcome Atalanta to the Allianz Stadium on matchday 28 of the Serie A season.