George Galloway sweeps to a shock victory in the Bradford West by-election, and local people say the win was inspired, in part, by young Muslims going against their Labour-supporting elders.

Please wait while this video loads. If it doesn't load after a few seconds you may need to have Adobe Flash installed.

Respect's Galloway recorded a 10,000 vote swing to the Respect party in an area Labour has held almost solidly since the early 1970s.

Labour's deputy leader Harriet Harman told Channel 4 News her party had expected to win the by-election. She said voters she had spoken to on a visit to the constituency a week earlier had said that they were going to vote Labour.

Labour went into the contest - sparked by the resignation due to ill-health of Marsha Singh - the overwhelming favourites with bookmakers.

Turnout in the poll was just over 50 per cent - considered high for such a contest, especially in an urban area.

Locals and campaigners in the Yorkshire constituency said that the galvanising of young Muslims who had never gone to the ballot before was decisive in the win, not least because they broke ranks with older generations in doing so.

Clan politics, known as Bradree, has long been a hugely influential force in Bradford, in which Muslims represent 22 per cent of the population at the last count (38 per cent in the Bradford West constituency).

The majority of the city's Pakistani community come from the Mirpur region, and inter-communal politics from Kashmir is influential in Bradford.

Mohammed Shafiq, chief executive of the Ramadhan Foundation, who had been on the campaign trail with Galloway for the last 48 hours, said that the win was historical, because it signalled a break from Asian communities voting for one party, en masse.

"What this win shows is that the time when unelected elders in the community say, 'we're all voting for Labour,' who would dictate to young Muslims how to vote, is over," he told Channel 4 News.

"What Galloway did is to stand up to that, and defeated it. I spent hours talking to young Muslims, whatever affiliation they had, they were sick of being told who to vote for.

"I think what has happened in Bradford West is an historical moment, because it shows that individuals in the community will vote for themselves and not as a group. That is a fantastic breakthrough, whatever you think of Galloway."

Please wait while this video loads. If it doesn't load after a few seconds you may need to have Adobe Flash installed.

The former Glasgow Hillhead and Tower Hamlets and Bow MP had also made frequent visits to Bradford University in recent months, delivering speeches, largely on British foreign policy.

Furqan Naeem, senior Labour Student member and the chair of University of Bradford Student Union Council, said: "George has captured the hearts and minds of the young students - especially people from Asian backgrounds who were previously not political. They have become the driving force of his campaign."

But he also accused him of political opportunism, saying that he had "never done anything for Bradford before".

Galloway's popularity amongst young Muslims percolated into social media; a Facebook page "let's elect George Galloway for Bradford West" attracted more than 4,000 of mainly young members, who used it to organise campaign events.

One of the members, Rash Ibrahim, posted: "2 fingers up at the 'Mirpuri village politics' imported to the UK, particularly Bradford...where voting is about who you know, financial and personal gain for the candidate...long live the youth that made this possible."

Galloway's campaign was largely based on what has become the issue that has defined him; an acerbic objection to British foreign policy in the Middle East.

On the campaign trail, he drummed up support by opposing the country's continuing presence in Afghanistan, warned against military action in Iran, and his key selling point of supporting the Palestinian cause.

As such, he had been labelled by his critics as something of a one trick pony, but supporters said he had also garnered support through his opposition to government cuts and the closing of Bradford's Westfield shopping centre.

Harriet Harman, deputy leader of the Labour Party, said it was too early to say whether Labour's defeat was about Iraq and Afghanistan and added that she and her colleagues would be talking to people on the ground, both inside and outside of the party.

"It is self-evident that those people who said on the Thursday before they were Labour supporters and who didn't support us on the day of the vote, clearly our engagement with them, our connection with them, our rootedness with them was not robust enough.

"It was not deep enough self-evidently. Otherwise they would not have been taken forward by the bandwagon. We do have to look at this in a serious way and learn lessons from it."

Respect's win means that Bradford's three constituencies are now represented in Westminster by three different parties, with the Liberal Democrats' David Ward in Bradford East and Labour's Gerry Sutcliffe in Bradford South.

FactCheck: Was Galloway’s win ‘the most sensational’ in British history?

Please wait while this video loads. If it doesn't load after a few seconds you may need to have Adobe Flash installed.