Mario Mandzukic's 84th-minute header earned Juventus a much-needed home victory over Sporting Lisbon in the Champions League.
With both sides having already beaten Olympiacos and lost to Barcelona, this was a crucial game in what appears a race for second spot in Group D.
Sporting went ahead in the 12th minute through an Alex Sandro own goal but Miralem Pjanic equalised in the first half and, just when it looked like Juventus would have to settle for a draw, Mandzukic secured a 2-1 victory.
Massimiliano Allegri's side have wobbled in Serie A recently, failing to beat Atalanta after taking a 2-0 lead and then losing at home to Lazio at the weekend.
And their woes deepened with an opening goal for Sporting that was a personal horror show for Sandro.
Having allowed a Bruno Fernandes through ball to reach Gelson Martins, the defender then diverted the ball into his own net after Gianluigi Buffon pushed it against him in saving the shot.
Juventus responded well and Rui Patricio needed to be alert to keep out a Sami Khedira shot that was heading for the bottom corner.
Jeremy Mathieu then helped out his keeper with a crucial touch to deny Mandzukic before Paulo Dybala poked a shot wide.
There was nothing defenders or keeper could do to prevent Pjanic equalising in the 29th minute, however.
Rodrigo Battaglia was penalised for a foul on the Bosnian just outside the box and Pjanic curled the free-kick over the wall and into the corner, leaving Patricio rooted to the spot.
The momentum stayed with Juventus for the rest of the half but they could not find another goal, with their best effort coming just before the break when Patricio pushed Gonzalo Higuain's powerful volley around the post.
Allegri was clearly unhappy with what he had seen and sent his players back out early for the second half.
The viewing did not become any easier for the Bianconeri faithful as Sporting kept Juve at arm's length, denying them any clear-cut opportunities.
Allegri threw on Douglas Costa and immediately got his reward as the winger created the winning goal within seconds of his arrival.
Costa sent over a terrific cross from the left, matched by the quality of Mandzukic's diving header.
Sporting had one glorious chance to equalise but Seydou Doumbia was unable to get a touch on Fernandes' pass with the goal gaping.