Amir Hossein Hosseinzadeh gave Iran the lead from the spot after 17 minutes. Mohammad Mohebi had been brought down inside the area and the referee pointed to the spot.
In the 26th minute Tanzanian defender Ibrahim Hamd deflected Mohebi’s shot for Iran to go 2-0 up.
Substitute Alireza Jahanbakhsh scored another goal for Iran, but it was ruled out for a handball.
Iran who is placed 21st in the latest FIFA ranking had previously lost 2-1 to Russia in another International match played last week.