Jeremy Corbyn accused Boris Johnson of having made “racist remarks” as the pair clashed over Islamophobia and antisemitism in their parties in a crucial head-to-head debate less than a week before polling day.

Corbyn made the allegation during the BBC One leaders’ debate on Friday as he defended himself against Johnson’s charge that his handling of antisemitism complaints within Labour was a “failure of leadership”.

After setting out what his party has done to address antisemitism, Corbyn implied Johnson had failed to tackle Islamophobia in the Conservatives and had used racist language himself.

“There are problems of Islamophobia within our society also and there are problems of language that is used. I do not ever use racist language in any form to describe anybody in this world or in our society,” he said.

Johnson said any Tories guilty of Islamophobia or racism were “out first bounce” even though some remain candidates after apologising. He then went on the attack, saying: “I think that Mr Corbyn’s handling of this particular issue, his unwillingness to take a stand and stand up for Jewish people in the Labour party and put an arm round them is a failure of leadership.”

Corbyn was then more explicit in his attack on Johnson, who has been criticised in the past for articles describing black people as “picaninnies” with “watermelon smiles” and comparing Muslim women wearing the full face veil to “bank robbers” and “letterboxes”.

The Labour leader said: “A failure of leadership is when you use racist remarks to describe people from different countries or in our society. I will never do that … I hope that the prime minister understands the hurt that people feel when they hear remarks and articles he has written.

“I hope he will regret those and understand the importance of using respectful language towards people of all faiths and religions and languages in what is a multicultural society.”

The exchanges were the most dramatic altercation during the hour-long televised debate on Friday evening, continuing a row that has raged all campaign about both parties tolerating racism within their ranks and picking candidates who have made racist remarks.

Play Video 2:55 Austerity, racism, the NHS and Brexit: Corbyn and Johnson clash in BBC debate – video highlights

Labour has been fighting allegations that it has failed to deal with a deluge of complaints about antisemitism, with the chief rabbi, Ephraim Mirvis, warning that Jews feel “anxious” about the prospect of a Corbyn-led government.

At the same time, the Tories have been dogged by accusations that they have failed to deal with Islamophobia, with Johnson himself under fire over his comments.

After the leaders clashed over racism, Corbyn went on to suggest Johnson was guilty of political lies in the election and referendum, saying: “There has to be a test on the statements made. If people paint slogans on the side of a bus that are totally unsustainable, perhaps it’s time that we did have independent monitoring.”

Johnson gave a jovial answer about politicians who lie, saying “they should be made to go on their knees through the chamber of the House of Commons scourging themselves with copies of their offending documents”.

Lying liar lies some more as Boris Johnson braves BBC studio for debate | John Crace Read more

A snap poll from YouGov found 52% of Britons asked after watching the debate believed Johnson won and 48% Corbyn. The pollster said it fell within the margin of error and so could be considered another draw. Those surveyed said Corbyn was more trustworthy than Johnson by 48% to 38% but Johnson was considered more prime ministerial by 54% to 30%.

Earlier in the debate, the two men clashed over whether the future of Britain should be capitalist or socialist and their plans for the NHS.

They set out vastly different visions for the UK, with Johnson promoting free market capitalism in a post-Brexit Britain and Corbyn arguing for Scandinavian-style democratic socialism in the UK to tackle inequality

Corbyn said: “Socialism carried out in a democratic way in this country, in Scandinavia and other places, has raised the living standards of the very poorest. It was the postwar Labour government that raised up the very poorest. Our Labour government will do the same again.”

Johnson argued that a free market economy was the way forward and criticised John McDonnell, the shadow chancellor, for saying he wants to “foment the overthrow of capitalism”.

Corbyn hit back that “inequality has got worse” under the Conservatives and highlighted “150 billionaires in Britain, more people poor than ever”.

The leaders also jousted over the NHS, which has become a huge issue during the campaign, with Corbyn accusing Johnson of putting it at risk through a planned trade deal with Donald Trump.

Johnson said the claim from Corbyn was “pure Bermuda Triangle stuff”.

“We’ve heard it time and time again from the Labour party during this election campaign. We’ll be hearing about ‘little green men’ next,” he said.

Johnson also went on the offensive over the NHS, saying: “What I think is totally incomprehensible is to have a system where you try to get more nurses and more staff into the NHS and simultaneously ask the whole of the public sector to work a four-day week.”

Corbyn said there was “no plan to bring in a four-day week in the NHS”, even though McDonnell has previously said all sectors including the NHS would eventually be covered by the aim to reduce working hours.

After the debate, a spokesperson for Corbyn, who toured the spin room, said Johnson’s claims that Labour would put up corporation tax to the highest level in Europe were a “barefaced lie” which showed “either a worrying level of ignorance of how other major economies are run or again this deliberate misleading [of] the public which seems to be his special number”.

He added: “He’s completely wrong on corporation tax – 26% is lower than France, lower than Italy, Germany. Lower than we were in 2010.”

But Matt Hancock, the health secretary, doubled down on Johnson’s incorrect claim that Britons would pay the highest taxes in Europe under Labour.

He said: “That is true in terms of corporation tax. He was very clear about that. If you add up the total amount that is in the Labour manifesto plus all the commitments they made after the manifesto that aren’t properly costed then you’ll find, to pay for that, taxes will have to go up on everybody.”