* Payments technically breach sanctions, say U.N. officials
* Britain, United States say al Shabaab are terrorists
* Pirates say forced to deal with militants
* UK shipping says ransoms only way to rescue hostages
NAIROBI, July 6 (Reuters) - Ransoms paid to Somali pirates to free merchant vessels are ending up in the hands of Islamist militants, laying shipping groups open to accusations of breaching international sanctions, U.N. officials told Reuters.
John Steed, the principal military adviser to the U.N. special envoy to Somalia and head of the envoy's counter-piracy unit, said links between armed pirate gangs and Somalia's al Qaeda-affiliated rebels were gradually firming.
"The payment of ransoms just like any other funding activity, illegal or otherwise, is technically in breach of the Somalia sanctions regime if it makes the security situation in Somalia worse," said Steed.
"Especially if it is ending up in the hands of terrorists or militia leaders -- and we believe it is, some directly, some more indirectly," said Steed, a retired military officer.
Ransom demands have risen steadily in recent years. According to one study, the average ransom stood at $5.4 million in 2010, up from $150,000 in 2005, helping Somali pirates rake in nearly $240 million last year.
Steed acknowledged he had no proof of an operational relationship between the pirates and the al Qaeda-linked al Shabaab rebels who control much of southern and central Somalia and parts of the capital Mogadishu.
Some political analysts said the policy of some Western governments to endorse the payment of ransoms, seen as fuelling the insecurity, is at odds with their financial support for the Somali government and the African troops propping it up.
Under the terms of the arms embargo on Somalia, financial support to armed groups in the Horn of Africa country is banned. Both the United States and Britain regard al Shabaab as a terrorist organisation.
The U.N.'s Office on Drugs and Crime (UNODC) says pirates are increasingly launching their cross-ocean raids from the al Shabaab-controlled southern coastal city of Kismayu. Recruitment for pirates from the region was also on the rise, it said.
"Detained pirates tell us that some level of cooperation with al Shabaab is necessary to run a criminal enterprise," said Alan Cole, piracy programme coordinator at UNODC.
Al Shabaab sources agree.
"If there was no relationship between us, there is no way the pirates would be able to operate, or carry their weapons within zones we control," said an al Shabaab militant based in the pirate haven of Haradhere, north of Mogadishu.
BIGGEST GAMES IN TOWN
Natznet Tesfay of Executive Analysis said al Shabaab was heavily involved in smuggling through Kismayu, slapping taxes on illegal charcoal exports to the Gulf, arms shipments from Yemen and electronic goods destined for the region.
"Piracy and contraband smuggling are the two biggest games around," said Tesfay at the specialist intelligence company.
Tesfay said she had yet to see evidence of an "operational relationship" between the pirates and al Shabaab but that the militants had a reputation for monopolising key income-earning sectors once they had taken control of an area.
In February al Shabaab seized a number of pirate gang leaders in Haradhere and forced them to accept a multi-million dollar deal under which the pirates would hand over 20 percent of future ransoms.
A Reuters investigation found the following payments had been made to al Shabaab's "marine office":
On Feb. 25: $200,000 from the release of the Japanese-owned MV Izumi after pirates received a $4.5 million ransom.
On March 8: $80,000 from the $2 million release of the St Vincent & Grenadines-flagged MV Rak Africana.
On March 9: $100,000 after the Singapore-flagged MV York was freed for $4.5 million.
On April 13: $600,000 from the release of the German ship Beluga Nomination after a $5.5 million ransom was paid.
On April 15: A $66,000 share of the $3.6 million ransom handed over for the Panama-flagged MV Asphalt Venture.
On May 14: $100,000 from the release of two Spanish crew of the Spanish-owned FV VEGA 5.
The amounts were corroborated by pirates, al Shabaab militants and residents of Haradhere.
ONLY WAY TO FREE HOSTAGES
"Some money has to be ending up in al Shabaab's hands," said Michael Frodl, a Washington Lawyer and head of C-level Maritime Risks, which advises Lloyd's of London underwriters.
Frodl questioned whether payment of ransoms would be even an indirect breach of the arms embargo, but said that if proved, it might break laws in the United States and Britain against funding terrorism.
Sanctions experts said ransoms could violate the arms embargo if they were voluntary financial support to armed groups in Somalia, but said the payments could be considered extortion, and therefore involuntary, blurring the issue.
Some Horn of Africa experts argued there appeared to be no clear systematic link between pirates and al Shabaab's central command, but there probably were ties at a more local level.
It was likely there was a bleeding of pirate money to local rebel commanders through clan ties, "taxes" or even protection money, they said.
C-level Maritime's Frodl said the U.S. Treasury's Office of Foreign Assets Control (OFAC) carried out reviews of all potential ransom payments to determine if the pirate group in question had ever handed over part of a ransom to al Shabaab.
"Most times OFAC has authorised payment because it has found no link," Frodl said. "But if there is indeed a 20 percent 'tax' being applied by Shabaab against pirate ransoms in Haradhere, a major pirate hub it now controls, then things could change."
In April 2010, President Barack Obama issued an executive order barring any financial dealings with 11 masterminds of the Somali conflict. According to the OFAC, two of them are in charge of pirate gangs.
While Washington has firmly opposed ransom payments, counter-piracy experts say London -- home to the world's shipping and insurance industries -- has demonstrated a conspicuous lack of appetite to follow suit.
The UK Chamber of Shipping said it would continue to consider piracy a criminal activity, until proof emerged of financial ties between the sea-bandits and insurgents.
The association welcomed what it called the government's "balanced view" in refraining from preventing ransom deals.
"Frankly, that's the only way we get people released," said Mark Brownrigg, the chamber's director-general. (Additional reporting by Mohamed Ahmed in Mogadishu and Jonathan Saul in London, editing by Tim Pearce) (For more Reuters Africa coverage and to have your say on the top issues, visit: af.reuters.com)