Labour MPs have hit out at David Cameron for lending his support to an “Islamophobic” campaign against their party’s Muslim candidate for Mayor of London.

David Cameron used his weekly platform at PMQs to echo attacks made by Zac Goldsmith against Sadiq Khan – which have prompted accusations the Tories’ campaign is “racist”.

Mr Khan has long campaigned against Islamic extremism and described it as “a cancer eating at the heart of our society”.

But the Tory campaign has sought to draw links between Mr Khan and extremist figures by repeatedly noting he has shared platforms with his local imam, Suliman Gani.

Mr Cameron said: “Suliman Gani – the honourable member for Tooting has appeared on a platform with him nine times. This man supports IS [the so-called Islamic State].

“They are shouting down this point because they don’t want to hear the truth. Anyone can make a mistake about who they appear on a platform with … but if you do it time after time after time it is right to question your judgment.”

The Prime Minister did not mention that Mr Goldsmith himself had his photograph taken with Mr Gani outside a Conservative party event, after being introduced.

Labour MP Chuka Umunna tore into Mr Cameron for the comments.

“So David Cameron has joined Zac Goldsmith's Islamophobic campaign against Sadiq Khan. Utterly disgraceful,” he said.

Mayor of London 2016 - the candidates at a glance Show all 7 1 /7 Mayor of London 2016 - the candidates at a glance Mayor of London 2016 - the candidates at a glance Sadiq Khan - Labour The MP for Tooting, Sadiq Khan says the mayoral election will be a 'referendum on the Tory housing crisis'. He has also pledged to freeze fares until 2020. Son of a bus driver, and doesn't let anyone forget it. His Conservative opponent has made claims about people who he has previously associated with - but attacks so far have failed to stick Mayor of London 2016 - the candidates at a glance Zac Goldsmith - Conservative The MP for Richmond, Zac Goldsmith is a longstanding campaigner against the expansion of Heathrow airport. Despite his environment credentials - he once edited The Ecologist magazine - the Tory candidate has said he would 'rip out' Boris Johnson's cycle lanes if they don't work. A very wealthy man, his campaign has been dogged by accusations of racism against Sadiq Khan Mayor of London 2016 - the candidates at a glance Sian Berry - Green Party A councillor in the London Borough of Camden, Sian Berry is campaigning on improving homes for renters, cleaning up London's air pollution, and flattening fare zones to help Londoners. She previously ran as the party's mayoral candidate in 2008. In 2012, the Green Party came in third place Mayor of London 2016 - the candidates at a glance Caroline Pidgeon - Liberal Democrat A Liberal Democrat London Assembly member for eight years, Caroline Pidgeon has a strong record on the Assembly's transport committee standing up for commuters and cyclists alike. She wants to set up a £2 billion housing investment fund and make all the capital's buses zero emission Mayor of London 2016 - the candidates at a glance Peter Whittle - UKIP UKIP hasn't fared so well in London in previous elections, but is hoping for a breakthrough this time. Peter Whittle has been UKIP's culture spokesperson for two years. He tends to focus on the impact of immigration on London's housing crisis Mayor of London 2016 - the candidates at a glance George Galloway - RESPECT George Galloway has made a habit of defying the odds and pulling off stunning victories when standing for Parliament. His campaign - based on the slogan 'a London for all' has so far failed to make headway in the polls - has his luck run out? Mayor of London 2016 - the candidates at a glance Sophie Walker - Women's Equality Party A journalist, Sophie Walker is campaigning for the little-known Women's Equality Party. She is pledging to make 'equality and diversity the fuel that drives our nation's capital' with measures to increase women's representation in enterprise, more affordable homes and flexible childcare

“The PM’s comments seek to shift the London Mayoral campaign from housing and transport – on which Sadiq is winning – to religion. Appalling.

“[David Cameron] thinks it is a crime for Sadiq Khan to be a Muslim and have been a human rights lawyer.”

Labour MP Jo Cox added: “Shame on the Prime Minister for joining Zac Goldsmith's Islamophobic campaign against Sadiq Khan. Disgraceful.”

Most polls suggest Mr Khan has a substantial lead over Tory candidate Mr Goldsmith in the race to become Mayor of London.

Mr Khan has pledged to freeze transport fares and use City Hall to directly build more affordable homes.

Mr Goldsmith is an opponent of Heathrow Airport expansion and has focused his campaign on Mr Khan’s character.

Other candidates include Sian Berry of the Green Party, Caroline Pidgeon of the Liberal Democrats, and Peter Whittle of Ukip.