An Iranian diplomat who Egypt had been briefly detained and questioned for spying left Cairo on Monday, Egypt's official news agency MENA reported.
Ties between Egypt and Iran were severed after Iran's 1979 Islamic revolution and after Egypt made peace with Israel the same year. But they have been improving since a popular uprising toppled Egyptian President Hosni Mubarak on February 11.
Qassem Hosseini was accused of spying for Iran with the intention of harming the interests of Egypt but was released when his diplomatic status was confirmed. The official news agency said he left Cairo bound for Dubai.
It was not immediately clear if he had been expelled and there was no immediate comment from Egypt's Foreign Ministry.
Although Egypt and Iran do not have full diplomatic relations, each has a diplomatic mission in the other's capital.