European Union negotiators and Turkey have reached a deal to halt illegal migration flows to Europe that would mean all refugees and migrants arriving in Europe from Sunday would be sent back across the Aegean sea.
The European council president, Donald Tusk, negotiated with the Turkish prime minister, Ahmet Davutğlu, on Friday morning, and the agreement has been made.
"The Turkey agreement has been approved," Finland's prime minister, Juha Sipilä, said on Twitter.
The agreement, which will mean all refugees and migrants who arrive in Greece from Sunday will be returned to Turkey once they are registered and their asylum is processed, is expected to be formally signed off later today.
Under the pact, Ankara would take back all illegal migrants who cross to Greece, including Syrians, in return for the EU taking in thousands of Syrian refugees directly from Turkey and rewarding it with more money, early visa-free travel and progress in its EU membership negotiations.
Turkey has promised that all returned people will be treated in line with international law, including a guarantee that they will not be returned to the countries that they have fled from.
While the talks were under way, Turkish President Tayyip Erdogan accused the EU of hypocrisy over migrants, human rights and terrorism after a few dozen supporters of the separatist Kurdistan Workers Party (PKK) set up protest tents near the EU summit centre.
Erdogan said Europe was "dancing in a minefield" by directly or indirectly supporting terrorist groups.
Europeans need to look at their own record on migrants before telling Turkey what to do, he said, adding that Ankara would only listen to EU criticism on rights when it was correct.
"At a time when Turkey is hosting three million, those who are unable to find space for a handful of refugees, who in the middle of Europe keep these innocents in shameful conditions, must first look at themselves," Erdogan said in a speech broadcast on television.
Additional reporting by Reuters