Iran's Tasnim news agency said bilateral relations and the new U.S. strategy in Afghanistan were at the heart of the negotiations.
Khwaja Asif will visit Turkey tomorrow to discuss the situation in the region.
The Iranian president expressed Tehran's readiness for working with Pakistan toward promoting regional peace and stability, saying Iran believes the solution to regional conflicts can be found inside the region, according to his official website.
He said law and order situation in Afghanistan will also be discussed.
Iranian Foreign Minister Mohammad Javad Zarif has met with his Pakistani counterpart Khawaja Muhammad Asif in Tehran to discuss bilateral ties and the latest regional and global developments.
The Iranian Foreign Minister Dr. Javad Zarif reaffirmed Iran s commitment to deepening relations with Pakistan in diverse fields including in trade, investment, connectivity as well as border management.
"Afghanistan, the United States and its allies should close their borders to leaders of terrorist, militant groups carrying out acts of terrorism against Pakistan", he added.
Foreign Minister Khawaja Asif met Turkish Prime Minister Binali Yildirim in Ankara, as part of his regional tour to garner support for Pakistan in the backdrop of US President Donald Trump's new strategy for Afghanistan and South Asia.
Pakistan is hopeful of a positive outcome of the ministers visit since the months-old strained ties between Iran and Saudi Arabia are on the mend.
Security and regional stability was important for Iran and both countries shared the same views on resolving regional problems, the Iranian president was quoted as saying.
Asif said he will travel to Turkey on Tuesday to try his best to reach a regional consensus on Afghanistan.
Confronting extremism and active terrorist groups in the region and working together to establish peace, stability and security in Afghanistan through regional and multilateral political talks were among the other issues Zarif touched upon in this meeting.