Turkey has since the 1990s maintained several military bases in the autonomous Kurdistan region of north Iraq, where the Kurdistan Workers' Party (PKK) rebel group also has bases.
"The cabinet decided to reject the presence of any foreign bases or forces on Iraqi land and to reject the entry of any foreign military forces into Iraqi land," government spokesman Ali al-Dabbagh said in a statement.
And it "recommends that parliament cancel or not extend any treaty signed in the past with any foreign state that allows the presence of foreign forces and military bases on Iraqi land or the entry of these forces," he said.
A high-ranking Iraqi official said that the decision was aimed at Turkish military bases in the north Iraq province of Dohuk, one of the three provinces that make up the Kurdistan region.
The treaty in question "is the one that Saddam Hussein signed in 1995 allowing Turkish forces to have a presence in Iraq's northern regions to pursue the Kurdistan Workers' Party," the official said on condition of anonymity.
Baghdad's move appears to be linked to a request by the Turkish government on Monday for its parliament to extend the mandate for its armed forces to attack PKK bases in north Iraq.
"The cabinet condemns this decision," Dabbagh said in a separate statement referring to that request and adding that Turkish forces crossing into Iraq "is a violation of Iraq's sovereignty and security."
Ties between Iraq and Turkey have been marred by various disputes this year, including Ankara's refusal to extradite Iraqi Vice President Tareq al-Hashemi, who has been sentenced to death in absentia by an Iraqi court.
Iraqi Prime Minister Nuri al-Maliki last month declined an invitation to visit Turkey, a decision his spokesman said was taken because "his schedule is crowded and he is busy."
In August, Maliki accused Turkey of treating the Kurdistan region, with which it has close economic ties, as an "independent state."
Earlier that month, Turkish Foreign Minister Ahmet Davutoglu visited the disputed northern Iraqi city of Kirkuk without informing Baghdad, infuriating Baghdad and taking relations to a new low.
In July, Iraq warned Ankara against "any violations" of its territory and airspace, and instructed the foreign ministry to register a complaint with the UN Security Council, after Turkish jets bombed Kurdish rebels in Kurdistan.
A few days earlier, Iraq called on Turkey to stop accepting "illegal" transfers of crude oil from Kurdistan, which an official from the region said had begun earlier in the month.