By Andrew Osborn
BOSTON (Reuters) - British Prime Minister David Cameron paid tribute to the victims of the Boston marathon bombing on Tuesday in a visit to the site of the attack, saying Britain stood shoulder to shoulder with the United States against terrorism.
On the second day of a three-day trip to the United States, Cameron visited the memorials to the victims at Copley Square, accompanied by Massachusetts Governor Deval Patrick.
Three people were killed and more than 260 injured in the April 15 bombings.
Cameron made a special trip to Boston after meeting President Barack Obama in the White House on Monday to discuss the Syrian conflict and next month's G8 summit in Northern Ireland.
"Everyone in the UK stands with your great city and your great people," Cameron told reporters in the square.
It was crucial to challenge the "narrative of violent extremism," he added, which meant "standing for the values that we believe in" such as freedom, democracy and diversity.
"We know how important it is to stand up and say the terrorists will not win," the prime minister added. "We will never give in to terrorists."
Ethnic Chechen brothers Tamerlan Tsarnaev, who died in a shoot-out with police, and Dzhokhar Tsarnaev were suspected of setting off bombs at the marathon's finish line. Dzhokhar Tsarnaev is in a prison west of Boston, charged with crimes that could carry the death penalty if he is convicted.
Cameron also met members of Boston's emergency services to hear how they coped with the bombing.
The London marathon took place six days after the attack and began with a 30-second silence for the victims. Many of the London runners wore black ribbons in memory of the dead.
"I'm here to tell Bostonians that Londoners, like all Britons, stand shoulder to shoulder with them," Cameron told the London Evening Standard newspaper separately.
"For those who seek to try and disrupt our way of life, our message is clear: be it Boston or London, we will be strong."
After meeting Cameron on Monday, Obama thanked the London marathon runners for dedicating the race to the Boston victims.
On Monday, Cameron became the first British serving prime minister to visit the FBI operations center in Washington, from where the hunt for the Boston bombers was conducted.
Cameron, who was accompanied by the new chief of Britain's MI5 security service, has said he wants to see whether Britain can learn from Boston's experience.
Cameron also visited the Massachusetts Institute of Technology on Tuesday, where he dropped into a robotics laboratory to hear about how such technology is being used for medical purposes.
(Editing by Vicki Allen)