"Zenit and Roberto Mancini have reached an agreement over early termination of his contract", Zenit said in a statement.
Mancini replaced Mircea Lucescu as Zenit boss last summer, agreeing a three-year deal with the option of a further two on top.
Mancini, who has reportedly been engaging in talks with Italy to take the helm of the first team, is to leave Zenit after their final league game in the 2017/2018 season against Khabarovsk.
How to Watch Premier League Championship Sunday
Manchester City manager Pep Guardiola says Kyle Walker can be even better if he works on key areas of his game. Southampton stays up with a win or draw, while they can also lose and likely still survive.
"Tomorrow will be the official presentation at Coverciano, it will be the formalisation of a long-standing discourse". He also won Italian Cups with Inter, Fiorentina and Lazio.
Luigi di Biagio, the coach of Italy's Under-21 side, is in caretaker charge of the national team.
Since leaving Etihad Stadium in 2013, Mancini has managed Galatasaray and Inter Milan before joining Zenit in June of 2017.
His first matches in charge will come against Saudi Arabia on May 28, France on June 1 and the Netherlands on June 4.
That was followed by a stint at City, where he won the 2012 Premier League title and the FA Cup in a four-season spell.