Three men arrested attempting to cross the Iraqi border after joining Kurdish forces to fight the so-called Islamic State group in Syria have been released, the BBC understands.
Jac Holmes, from Bournemouth, Joe Akerman, from Halifax, and Irish citizen Joshua Molloy were detained by the Kurdistan Regional Government.
Mr Holmes posted on Facebook: "Got out of jail peeps, thanks for the support."
His mother met with Kurdistan officials on Friday to help secure his release.
The three men had been returning home at the time of their arrest, crossing from Syria into Iraq.
They were held for more than a week in a prison in Erbil.
Mr Ackerman updated his status on Facebook, simply posting: "Free".
"We are helping two British men make arrangements to leave Kurdistan after they were released from custody," a Foreign Office spokeswoman told the BBC.
Confirming the release of Mr Molloy, a former Royal Irish Regiment soldier, Ireland's Foreign Affairs Minister Charlie Flanagan said: "I welcome Joshua's release and I am pleased that he is now on his way home to join his family in Ireland."
Emma Vardy, Home Affairs Correspondent, BBC South
We understand the men had been waiting on the border between Syria and Iraq for several weeks trying to cross. However, the border was closed.
They made their way to another point to cross and were arrested and told they were crossing into Iraq illegally.
The border is a politically sensitive zone between Iraq and Syria. The two countries have numerous groups in conflict with one another.
Jac Holmes's mother told me it had been an anxious time as the days passed, and that she had visited Kurdish officials in London to do what she could to get Jac and the other men released.
She wrote "I was prepared to chain myself to the railings" to try to ensure the men's safe passage home.
Kurdish supporters in the UK have rallied around in support Mr Holmes during his time fighting in Syria. He is one of a number of western volunteers fighting with the Kurds.
They call him a "hero", while British officials continue to warn strongly against travelling to any conflict zones.
The British Government maintains that anyone fighting abroad could find themselves breaching UK terrorism laws.