At least 15 protesters have been killed since the unrest erupted Monday.
Iranian state television cited “unrests” and “curfew” in Iraqi cities for the reason for the border closures. It urged Iranians avoid any travel to Iraq while urging Iran's Shiite pilgrims in Iraq to avoid further travel between cities.
The decision came as millions of Iranians were preparing to visit Iraq for annual pilgrimage to Shiite sites.
Kuwait meanwhile has urged its citizens in neighboring Iraq to leave the country. The state-run KUNA news agency also encouraged those hoping to travel to Iraq to delay their plans over the eruption of violent street clashes between rival Shiite groups in the country.
The tiny Gulf Arab sheikhdom of Kuwait shares a 254 kilometer (158 mile)-long border with Iraq.
Dubai's long-haul carrier Emirates stopped flights to Baghdad on Tuesday over the ongoing unrest in Iraq. The carrier said that it was “monitoring the situation closely.”
It did not say whether flights would resume for Wednesday.
Protesters loyal to cleric Muqtada al-Sadr, who resigned Monday, pulled down the cement barriers outside the government palace with ropes and breached the palace gates. Many rushed into the lavish salons and marbled halls of the palace, a key meeting place for Iraqi heads of state and foreign dignitaries.
Iraq’s military announced a nationwide curfew, and the caretaker premier suspended Cabinet sessions in response to the violence. Medical officials said dozens of protesters were wounded by gunfire and tear gas and physical altercations with riot police.