Iran has given custody of eight British servicemen to British diplomats, ending an incident that had threatened to grow into a major diplomatic crisis.

British Foreign Secretary Jack Straw says the six Royal Marines and two British sailors were turned over to the British diplomats in southern Iran early Thursday.

The crewmen had been held since Monday after their three patrols boats apparently strayed into Iranian waters near the border with Iraq.

Mr. Straw said his contacts with Iranian Foreign Minister Kamal Kharazi helped defuse a potential crisis, and he defended Britain's relations with Iran.

"We work hard on those relationships and sometimes those relationships are complicated but I'm in no doubt at all that our policy of engagement with the government of Iran and the Islamic People's Republic of Iran is the best approach," he said.

Mr. Straw said discussions continue with Iran over the return of the British boats and the crewmen's weapons and communications gear.