Gambia has withdrawn from the Commonwealth, a collection of 54 nations made up largely of former British colonies, saying it will "never be a member of any neo-colonial institution".

In an unexpected announcement broadcast by the west African nation on state television on Wednesday it was not immediately clear what prompted the decision to leave the Commonwealth, which is headed by the Queen.

"The government has withdrawn its membership of the British Commonwealth and decided that the Gambia will never be a member of any neo-colonial institution and will never be a party to any institution that represents an extension of colonialism," the statement said.

A British Foreign Office spokesman said: "Decisions on Commonwealth membership are a matter for each member government. We would very much regret the Gambia or any other country, deciding to leave the Commonwealth."

The Gambia joined the Commonwealth in 1965, when it gained independence from Britain. Although it remains a major tourist destination for British and other foreign holidaymakers, it has long had a troubled political relationship with its former colonial master.

The UK condemned the decision by the Gambia's president Yahya Jammeh – who seized power in a 1994 coup and who is one of Africa's longest-running and least democratic rulers – to execute nine death row prisoners, including one woman, without warning.

"I am deeply concerned over reports that nine prisoners on death row in The Gambia have been executed following comments by President Jammeh that all death row prisoners would now be executed," said foreign office minister Alistair Burt in a statement at the time.

The Gambia's decision to leave the traditionally English-speaking Commonwealth comes as Francophone African nations have expressed interest in joining the grouping. Former Belgian colony Rwanda joined the Commonwealth in 2009, while Gabon, a former French colony and key ally to France in Africa, sparked rumours it could follow suit when it announced it would introduce English as its second language.

The Gambian government did not give a reason for the decision to leave the Commonwealth. However, it comes amid a greater emphasis by Britain on human rights and increasing pressure to promote equality based on sexuality.

Jammeh on the other hand has been highly vocal in his condemnation of homosexuality, and last week gave a speech at the United Nations calling it a threat to human existence.

The UK ceased bilateral aid to the Gambia in 2011, but still gives roughly £8m per year to the country through multilateral donations to agencies.