David Cameron has argued for much of the night in Brussels with European Union partners determined to limit concessions on offer to help keep Britain in the bloc.
Fellow leaders and diplomats said an agreement that would allow Mr Cameron to return to London and launch a campaign to stay in the EU at a June referendum still seemed feasible by the end of a two-day summit today, but some said the outstanding issues were proving tough to crack, holding up the process.
A late-night dinner lasting more than five hours that was devoted to renewed arguments over the response to Europe's migration crisis also meant that a plan for an "English breakfast" on Friday for all 28 leaders to try and hammer out a final deal was now set to turn into "brunch".
European Council president Donald Tusk has said the summit could be extended until Sunday if a deal is not reached today.
"It might take longer than they think," Irish Prime Minister Enda Kenny said on leaving the summit centre, where Mr Cameron remained locked in overnight talks with top EU officials, French President Francois Hollande and the Belgian and Czech premiers.
Those three national leaders made the case on the various points of most resistance to a draft agreement brokered by summit chairman Donald Tusk, who told reporters: "For now, we have made some progress but a lot still remains to be done."
Mr Cameron finally left after his last meeting shortly after 5:30 am (0430 GMT), stepping swiftly and saying nothing.
Earlier, he appealed to EU leaders to help him settle the question of Britain's European Union membership for a generation by agreeing a "credible" deal he can sell to the British public.
But aides voiced frustration at a lack of concessions by partners who are wary of Cameron's bid to side-step EU regulation and cut immigration: "I would say the going is tough, this could be a long night," a British official told reporters.
"While many countries were saying they want to help, they want to make sure they keep Britain in the EU, there wasn't much sign of how they are planning to do that in practice, not showing much room for manoeuvre," the official added.
Paris has pushed for amendments to ensure Britain cannot veto actions by the eurozone countries or give City of London banks competitive advantage through regulation.
A group of east European states chaired by the Czechs is trying to hold back how far their citizens can be denied welfare benefits in Britain, or have family allowances reduced, as part of Cameron's drive to cut immigration.
And Belgian Prime Minister Charles Michel is fighting a rearguard action for the federalist cause to limit damage done to European plans for "ever closer union" by giving eurosceptic Britain a guarantee it need never share more sovereignty.
Italian Prime Minister Matteo Renzi said there had been some backward steps after an round-table session to discuss London's demands of reform in the EU before dinner: "I'm always confident but a bit less optimistic than when I arrived," he said.
German Chancellor Angela Merkel said: "The wish is there to keep Britain as a member of the European Union ... It became clear that agreement will not be easy for many, but that the will is there."
Many leaders said they felt they were at a historic turning point for European integration. No country has ever voted to leave the Union, and a British exit could deal a blow to the UK economy and certainly damage the EU's standing and self confidence.
How far the reform package will sway voters either way is unclear. Cameron's left-wing Labour opponent, Jeremy Corbyn, was also in Brussels where he echoed Conservative eurosceptics in describing the likely immigration deal as a "theatrical sideshow". But Labour plans to campaign to remain in the bloc.
Cameron told leaders on Thursday evening: "The question of Britain's place in Europe has been allowed to fester for too long and it is time to deal with it.
"If we can reach agreement here that is strong enough to persuade the British people to support the UK's membership of the EU then we have an opportunity to settle this issue for a generation," he said, describing the new relationship as a flexible one that allows countries to "live and let live".
Register for free to continue reading
Registration is a free and easy way to support our truly independent journalism
By registering, you will also enjoy limited access to Premium articles, exclusive newsletters, commenting, and virtual events with our leading journalists
Already have an account? sign in
Join our new commenting forum
Join thought-provoking conversations, follow other Independent readers and see their replies