Britain has thanked Cuban rescue workers for a “great gesture of solidarity” in helping the stranded passengers of a cruise ship struck by coronavirus.

In a glowing letter, the UK ambassador in Havana said he wanted to express his “immense gratitude and that of my country” for Cubans’ role in the operation.

Cuba allowed the cruise ship MS Braemar to dock in Havana and allow its 682 mainly UK passengers to fly home, after other countries such as the Bahamas and Barbados refused permission because of Covid-19 infections onboard.

But 43 Cuban workers, including a pilot, dock workers, police, and transport staff all had to go into quarantine for two weeks because of their close contact with the passengers. All have now been released and reunited with their families.

“During Operation Braemar, I witnessed the many qualities of the Cuban people, their humanitarian principles, kindness and hard-working attitude; facets of the Cuban character that I have come to know and love since I came to the country,” British ambassador Antony Stokes said in the letter dated 2 April, the day quarantine for the workers ended.

“I assure those who return home today that their great gesture of solidarity will last in the memory of the passengers and crew of the Braemar, their family and friends, who are now reunited thanks to their effort.”

The episode is a rare bright spot in relations between the UK and Cuba, a one-party state with a poor human rights record. The country has however won international praise for its conduct during the Covid-19 pandemic, sending more than 800 doctors abroad to work in virus hotspots as part of its long-standing policy of medical internationalism.

Cuba is still subject to a Cold War era embargo from the United States, its largest neighbour, which restricts exports including medical supplies.

A spokesperson for cruise operator Fred Olsen said at the time that “no other Caribbean ports were willing to accept the ship because of local sensitivities towards Covid-19 coronavirus”.

In the House of Commons at the time of the rescue, Dominic Raab, the foreign secretary, said he had called the Cuban foreign minister to say the UK was “very grateful to the Cuban government for swiftly enabling this operation and for their close cooperation to make sure it could be successful”.