The Serie A powerhouse have appointed ex- Italy manager the veteran manager to lead the team for the rest of the term.
The 66-year-old takes over from Igor Tudor, who was let go post the Lazio setback last weekend.
Tudor had joined the club in March as Thiago Motta's replacement but departed after seven months following a string of eight matches without a victory.
Spalletti guided Napoli to the Serie A crown in 2022-23 prior to assuming the Italy role, which missed out on the 2022 World Cup under former boss Roberto Mancini.
Under his guidance, they made it to Euro 2024 but were eliminated in the round of 16 by Switzerland.
However, Spalletti was sacked by Italy in June following a loss to Norway in World Cup qualifying, with the Azzurri at risk of missing out on a third consecutive World Cup.
Spalletti has also managed Inter Milan, Roma and Udinese in Serie A and secured two Russian Premier League titles with Zenit St Petersburg.
Juventus were temporarily led by Massimo Brambilla for their 3-1 win against Udinese on Wednesday which left them seventh in Serie A - trailing leaders Napoli by six points after nine matches.
In the Champions League, they sit 25th in the league phase, having lost once and drawn twice in their opening three matches.