BBC News, Damascus
Iraqi Prime Minister Nouri Maliki's trip to Syria has been hailed as historic by both countries.
Iraq's prime minister gets the full diplomatic treatment in Damascus
With diplomatic ties between Syria and Iraq only restored last year, the two governments are keen to stress their growing co-operation.
Syria was opposed to the American-led invasion of Iraq, and both the American and Iraqi administrations have accused the Syrian government of helping to fuel the Sunni insurgency.
But Iraqi officials told the BBC that Syria had agreed to tighten security on the border to prevent more insurgents slipping into Iraq.
There are to be increased economic ties between the two countries, and
Iraqi officials have agreed to help contribute the cost of accommodating 1.4 million Iraqi refugees in Syria.
For the two countries, this trip represents an acknowledgement that their futures are closely intertwined.
During the days of former Iraqi President Saddam Hussein, the relationship between the two countries was often poisonous.
Syria used to issue passports bearing the stamp: "All Arab countries except Iraq."
But since last year, there has been a concerted push to improve their bilateral relations.
Mr Maliki got the full diplomatic red carpet during his visit.
He met Syrian President Bashar al-Assad at the presidential palace in Damascus where the two men were filmed sitting on ornate, pearl-inlaid chairs - an acknowledgement of how seriously Syria was taking this visit.
The full diplomatic niceties also amounted to official Syrian support for the Iraqi government, something Damascus had withheld.
Many Syrians regarded - and some still do - the Iraqi government as American stooges.
At a press conference, the Iraqi prime minister was asked whether he had arrived with a message from the Americans.
He replied curtly that he was representing the Iraqi government.
Mr Maliki's trip to Syria comes after similar visit to Iran, which was publicly criticised by US President George W Bush.
The American government is trying to isolate both Iran and Syria.
But officials in the Iraqi delegation stressed that these two neighbouring countries are too important for Iraq to ignore, regardless of American objections.
Mr Maliki's visit was also aimed at shoring up support for his beleaguered government at home. Almost half of his cabinet has resigned.
Syria has a degree of influence over some Iraqi Sunni politicians and Mr Maliki will be hoping that they can persuade them to join is government.
For now, Mr Maliki and his delegation are buoyant about what they regard as a successful outing.
But the Iraqi prime minister will be expecting a tougher ride at home as he tries to save his government.