A far-right extremist waved his knife at horrified onlookers and warned they had "better move back" as he killed MP Jo Cox, a court has heard.

Thomas Mair, 53, is on trial at the Old Bailey accused of repeatedly shooting and stabbing the 41-year-old Remain campaigner a week before the EU referendum vote.

The mother of two was set upon outside her constituency surgery in Birstall, near Leeds, in front of her staff and shocked residents on 16 June.

Her assistant stepped in and hit the man with her handbag, while 78-year-old Bernard Carter-Kenny desperately tried to intervene but was stabbed too, the trial has heard.

999 call played to Jo Cox murder trial jury: 'There's hell on, it's chaos'

An eyewitness described how the man "just walked away with not a care in the world".

Another witness, taxi driver Rashid Hussain, pulled up at around the same time as Ms Cox's arrival at Birstall library in a silver Vauxhall Astra.

As he was giving his fare her change, he heard what sounded like a "firecracker", jurors were told.

Court artist sketch by Elizabeth Cook of Richard Whitman QC opening for the Prosecution as Thomas Mair, who is accused of the terror-related murder of Labour MP Jo Cox, sits in the dock at the Old Bailey (PA)

Mr Hussain demonstrated in the witness box how the man had stabbed Ms Cox five or six times in front of him.

He said: "When I reached near, he stepped back.

"I said: 'What are you doing? What's wrong with you?'

"He said: 'Move back, otherwise I'm going to stab you.'

"He was standing there with two ladies and another man. He said 'better move back.'

"He shot twice. He moved back and shot again."

Mr Hussain told jurors that by this point Ms Cox, who he had recognised as his MP, was bleeding from her mouth and was being helped by an Asian woman.

He said: "Jo's head was in her lap and she was pleading for Jo to stand up, talking about her kids.

"Her hands and clothes were covered in blood. She was the only person there helping her."

Jo Cox shooting - pictures of the crime scene Show all 7 1 /7 Jo Cox shooting - pictures of the crime scene Jo Cox shooting - pictures of the crime scene Media reports said Jo Cox, 41, who is a lawmaker for the opposition Labour Party, had been attacked as she prepared to hold an advice surgery for constituents in Birstall near Leeds REUTERS Jo Cox shooting - pictures of the crime scene A handbag and shoes lie on the ground as police cordon off an area after Jo Cox, was shot and stabbed by an attacker at her constituency in Birstall Getty Images Jo Cox shooting - pictures of the crime scene Medical equipment lies on the ground behind a police cordon in Birstall near Leeds REUTERS Jo Cox shooting - pictures of the crime scene Police stand behind a cordon in Birstall near Leeds. A British lawmaker Jo Cox was in critical condition after an incident in her constituency in northern England REUTERS Jo Cox shooting - pictures of the crime scene An eyewitness said the 41-year-old mother of two was left lying in a pool of blood on the pavement after her assailant struck in Birstall PA Jo Cox shooting - pictures of the crime scene Police stand behind a cordon in Birstall near Leeds REUTERS Jo Cox shooting - pictures of the crime scene Police stand behind a cordon in Birstall near Leeds REUTERS

Clarke Rothwell was in a nearby sandwich shop when he heard a "popping" noise and a woman scream.

Ms Cox then slumped to the floor before she was shot in the stomach, he said.

The man shouted words like "this is for Britain" and "put Britain first" before reloading his gun and shooting for a third time, the witness told jurors.

Tracy Bywood saw the killing as she was washing up in a care home kitchen overlooking the scene.

She said the MP "went down on the floor like a sack of potatoes", adding: "It was so awful to see a woman have such animosity shown towards her."

People attending a commemorative event to celebrate the life of Labour MP Jo Cox in Trafalgar Square (AFP/Getty)

Fighting back tears, she told the court: "I known it was a popping noise because I won't even buy Pringles any more, I can't handle the noise of the seal breaking."

Jack Foster told the court he saw the man, having shot Ms Cox once, reload his gun before shooting her twice more.

The England fan, who was wearing a red Three Lions football shirt ahead of a Euro 2016 game that evening, told how he shouted "f***ing leave her alone" but he took no notice.

"He reloaded his gun again, putting two cartridges in, cocked it and shot her on the floor," Mr Foster said.

He told the court he and two other men followed the man into a nearby street.

Mr Foster added: "He casually walked off. No remorse, no nothing."

Jo Cox tributes - in pictures Show all 20 1 /20 Jo Cox tributes - in pictures Jo Cox tributes - in pictures Floral tributes and candles are placed by a picture of slain Labour MP Jo Cox at a vigil in Parliament square in London AFP Jo Cox tributes - in pictures Tributes to Labour Party MP Jo Cox are placed on her houseboat in Wapping in London REUTERS Jo Cox tributes - in pictures The Union flag at half-mast on top of Portcullis House in London after Labour MP Jo Cox was shot and stabbed to death PA Jo Cox tributes - in pictures Labour leader Jeremy Corbyn (2R) and deputy leader Tom Watson (L) light candles as they attend a vigil to slain Labour MP Jo Cox in Parliament square in London AFP/Getty Images Jo Cox tributes - in pictures Labour Party leader Jeremy Corbyn and deputy leader Tom Watson (rear) arrive to leave tributes at Parliament Square PA Jo Cox tributes - in pictures People leave St Peter's Church after a vigil in memory of Jo Cox REUTERS Jo Cox tributes - in pictures Flowers left at Parliament Square opposite the Palace of Westminste, following the death of Labour MP Jo Cox PA Jo Cox tributes - in pictures People react as they look at tributes left for Labour Member of Parliament Jo Cox in Parliament Square, London REUTERS Jo Cox tributes - in pictures A man writes a message at Parliament Square PA Jo Cox tributes - in pictures People stop to look at tributes left at Parliament Square opposite the Palace of Westminster PA Jo Cox tributes - in pictures A woman arrives to lay flowers at a statue to Joseph Priestly in Birstall near to the scene where Labour MP Jo Cox was shot AFP/Getty Images Jo Cox tributes - in pictures Tributes at Parliament Square opposite the Palace of Westminster PA Jo Cox tributes - in pictures A woman places candles in tribute to Labour Party MP Jo Cox REUTERS Jo Cox tributes - in pictures A member of the public signs a memorial for British MP Jo Cox in Parliament Square, London EPA Jo Cox tributes - in pictures People sign messages of condolence for MP Jo Cox during a vigil in Parliament Square in London Getty Images Jo Cox tributes - in pictures Flags at half mast outside Scottish Parliament in Edinburgh, after Labour MP Jo Cox was shot and stabbed to death in the street outside her constituency advice surgery in Birstall PA Jo Cox tributes - in pictures People arrive in Market Square with floral tributes after the death of Jo Co Getty Images Jo Cox tributes - in pictures Floral tributes are placed in Market Square next to the statue of Joseph Priestley following the death of Jo Cox Getty Images Jo Cox tributes - in pictures Floral tributes are brought to the scene after the death of Jo Cox Getty Images Jo Cox tributes - in pictures A police officer carries bunches of flowers at the scene of the shooting of Labour MP Jo Cox in Birstall REUTERS

Julie Holmes, who witnessed the attack from her shop, It's A Cake Thing, on Market Street, told how Ms Cox's killer looked straight at her as if to say "here I am".

She said: "He took a step into the road and he looked around and he looked over to where I was standing.

"He looked me right in the eye and lifted the gun, not pointing it at me but as a gesture, saying 'here I am'."

David Honeybell, who had gone to see Ms Cox before her surgery, told jurors: "He just walked away with not a care in the world, he just walked away."

Another eyewitness, Stephen Connolly, said: "It was very cold, he just walked away."

Mair denies Ms Cox's murder, possession of a firearm with intent to commit an indictable offence and possession of an offensive weapon - a dagger.

He also pleads not guilty to causing grievous bodily harm with intent to Mr Carter-Kenny on the same date.

The trial continues.