The UK's decolonisation of the Chagos Islands in the Indian Ocean was unlawful and it should immediately end its administration of the archipelago that is now home to the Diego Garcia US military base, the International Court of Justice has ruled.

In a non-binding opinion issued on Monday, the World Court said the UK acted illegally when it divided the territory from Mauritius in 1965 and later displaced thousands of islanders.

Mauritius told the court, in a series of hearings, that it was forced to give up the islands during the decolonisation process in order to gain independence.

The country eventually won independence in 1968.

Its representatives also argued that the archipelago had been part of its territory since at least the 18th century and was seized unlawfully by the UK.

Chagos islanders demand to return home: in pictures Show all 10 1 /10 Chagos islanders demand to return home: in pictures Chagos islanders demand to return home: in pictures Chairman of the Chagos Refugees Group, holds his grandson Julien aloft outside The High Court in central London alongside then backbench Labour MP for Islington North Jeremy Corbyn on May 23 2007. Families expelled from the Chagos Islands by the British Government to make way for the Diego Garcia US airbase won their legal battle to return home Wednesday. The ruling was later overturned after the British government appealed AFP/Getty Chagos islanders demand to return home: in pictures Chagos islanders march by Parliament on October 22 2008. The British government on Wednesday won its appeal to Britain's highest court over previous rulings that allowed displaced islanders to return home AFP/Getty Chagos islanders demand to return home: in pictures Chagos islanders march by Parliament on October 22 2008 AFP/Getty Chagos islanders demand to return home: in pictures Chagos islanders march by Parliament on October 22, 200 AFP/Getty Chagos islanders demand to return home: in pictures A Chagossian man shows his identity card stating his birth place as the Solomon Island, Chagos on January 17 2005 in Port Louis, Mauritius AFP/Getty Chagos islanders demand to return home: in pictures Chagossian Islanders and their supporters arrive at the Court of Appeal in central London on February 5 2007, as they prepare to fight a court ruling which would prevent the islanders from returning to their homes in the remote Chagos archipelago AFP/Getty Chagos islanders demand to return home: in pictures Chagossian islanders outside of the Court of Appeal in London on February 5 2007 protest a court ruling which would prevent them from returning to their home islands AFP/Getty Chagos islanders demand to return home: in pictures Chagossian islanders outside of the Court of Appeal in London on February 5 2007 protest a court ruling which would prevent them from returning to their home islands AFP/Getty Chagos islanders demand to return home: in pictures Chagossian islanders outside of the Court of Appeal in London on February 5 2007 protest a court ruling which would prevent them from returning to their home islands AFP/Getty Chagos islanders demand to return home: in pictures Chairman of the Chagos Refugees Group, holds his grandson Julien aloft outside The High Court in central London alongside then backbench Labour MP for Islington North Jeremy Corbyn on May 23 2007. Families expelled from the Chagos Islands by the British Government to make way for the Diego Garcia US airbase won their legal battle to return home Wednesday. The ruling was later overturned after the British government appealed AFP/Getty

The UK maintained that Mauritius had given up the islands willingly, but the court found the agreement between the countries at the time was not based on "the free and genuine expression of the will of the people concerned".

The decolonisation process did not therefore comply with standards for self-determination, the ICJ said.

The Chagos Islands are currently part of British Indian Ocean Territory.

UK authorities evicted 2,000 people from the islands during the 1960s and 1970s so the US could build its strategically important military base.

Many of the evicted islanders were sent to Mauritius and the Seychelles but eventually resettled in the UK.

They have fought in British courts for years to win the right to return to their homes.

Reading a summary of a the 14-member tribunal's decision, presiding judge​ Abdulqawi Yusuf said the UK was "under obligation to bring to an end the administration of Chagos Islands as rapidly as possible".

The UN General Assembly asked the court in February 2017 to weigh in on whether the decolonisation process was concluded lawfully.

Although the opinion is non-binding, the court's statement will put significant pressure on the UK to consider its position.

While the US still operates its military base from the islands the court added that "all member states are under an obligation to cooperate with the United Nations in order to complete the decolonization of Mauritius."

Support free-thinking journalism and attend Independent events