Levski have put club scout Yasen Petrov and assistant coach Viktorio Pavlov in temporary charge of the 26-times Bulgarian champions until then.
"Ilian Iliev will be appointed as Levski coach after the end of the season. He will sign a three-year contract," Levski's chief executive Ivo Tonev told a news conference.
"I hope that all Levski fans will support Iliev and I want to see him staying here for a long time. There are too many coaching changes in recent seasons and we all see that the results are not good."
Ivanov replaced Nikolay Kostov last Tuesday but during his short tenure as Levski coach the Sofia-based club suffered a 1-0 defeat at champions Litex Lovech and a home loss to Ludogorets by the same scoreline.
"I'm not Levski coach anymore," Ivanov, twice Bulgarian Footballer of the Year, earlier told reporters. "I resigned because Levski now need an inner peace and there has been a lot of recent criticism."
Levski are fifth in the standings with 45 points from 22 matches, nine behind leaders and bitter city rivals CSKA Sofia, and are likely to miss out on a trophy for a third consecutive season.
Former Levski midfielder Iliev, who has been at the helm of Beroe since 2006 and led them to the Bulgarian Cup in 2010, will have to deal with a demanding and impatient fan base.
"I think that Levski have a psychological problem at the moment," the 43-year-old told local media.
"But I'm still coach of Beroe and we still have matches until the end of the season, so I just want to concentrate on it.
"The game between Levski and Beroe (on May 11) will be the most difficult in my career," added Iliev, who enjoyed a successful playing career in Portugal and won the domestic cup with Benfica in 1996.
Get the best features, fun and footballing frolics straight to your inbox every week.
Thank you for signing up to Four Four Two. You will receive a verification email shortly.
There was a problem. Please refresh the page and try again.