The Duke and Duchess of Edinburgh have sailed through the harbour in Malta before throwing a wreath and posy into the sea to commemorate British and Maltese lives lost during the Second World War.

On the second day of their trip to the island nation, Edward and Sophie boarded a military ship and sailed through Valletta harbour, where they were treated to dramatic views of the capital’s yellow limestone buildings.

Accompanied by the armed forces of Malta, the duke threw a wreath and the duchess a posy of flowers into the water before a gun salute sounded from one of the city’s high points.

The royal couple toured key wartime sites in Grand Harbour, Valetta (Aaron Chown/PA)

Earlier in the morning, Edward and Sophie opened a new monument to submariners who lost their lives in the Second World War – the Submariners’ Walkway.

The duke unveiled a plaque and then untied a ribbon to open the walkway, prompting applause from a group gathered nearby which included descendants of the submariners who fought in the conflict.

Speaking to them, Edward said: “It’s great to have that recognition now of the service.”

Three British submarines were especially commemorated – HMS Olympus, HMS Urge and HMS Upholder – the first two of which sank off the coast of Malta in 1942.

The royal couple paid a visit to the Maritime Museum in Birgu (Aarown Chown/PA)

The duke and duchess then visited the National War Museum, where they viewed a plaque marking the site where the late Queen Elizabeth II – then the Duchess of Edinburgh – “took the salute of the Mediterranean fleet before entering the harbour” in 1950.

The late Prince Philip, Duke of Edinburgh, was with the fleet as first lieutenant in HMS Chequers, according to the plaque.

Sophie touched the words “Duchess of Edinburgh” on the stone, and said it was “very special” to see.

The trip marks the 60th anniversary of Malta’s independence and celebrates the country’s shared heritage and continuing collaboration with the UK (Aaron Chown/PA)

After the boat journey, the duke and duchess walked to the Maritime Museum, saying hello to members of the public as they strolled past – many taking their phones out to snap photos and videos of the royal pair.

Once at the museum, Edward and Sophie spent a few moments on a balcony overlooking the harbour before entering a reception attended by armed forces personnel and members of the Maltese-UK Veterans’ Association.

The duke will later open a new headquarters for the Duke of Edinburgh International Award in Malta.