Carlos Queiroz has left his role as Iran coach following his side's defeat to Sweden in a friendly on Tuesday night.
The former Manchester United coach had already decided to call time on his four-year spell with the national team prior to matches against Austria and Sweden this week.
The 62-year-old, who took charge of Iran back in 2011, signed off with a 3-1 defeat to the Swedes.
"After four years of work with the national team, I am proud of the team and the individual players," Queiroz told the FFIRI website. "Now I am sad to leave the team, but that's life and I'm happy to be moving forward."
Queiroz, who has been manager of Real Madrid and Portugal during his career, was originally contracted to take Iran to the 2018 World Cup in Russia after signing a new deal following the Brazil World Cup last summer.