(CNN)A neo-Nazi who plotted to murder his local Member of Parliament with a sword was handed a life sentence in London on Friday.
Jack Renshaw, 23, pleaded guilty to planning to commit a terrorist act. He plotted to kill Rosie Cooper, the MP for West Lancashire, in 2017 with a sword similar to that used by Roman soldiers, according to a statement from the Crown Prosecution Service (CPS).
The court heard how Renshaw became obsessed with Nazi ideology at 14 years old and thought Britain was controlled by Jewish people. The court was also told that he targeted Cooper because she was from the Labour Party, which he blamed for immigration in the UK.
Renshaw raised his arm to the public gallery in what appeared to be a Nazi salute as he was taken out of the courtroom.
The judge, Honorable Justice Maura McGowan, said she acknowledged Renshaw was young, naive and came from a troubled background. However, she said: "You are an intelligent young man. You may be troubled but you know full well what you have done."
"Your perverted view of history and current politics has caused you to believe it right to demonize groups simply because they are different from you," McGowan continued.
"This is a case in which only a sentence of life imprisonment can meet the appalling seriousness of your offending," she ended.
There were gasps from the public gallery as the sentence was read out. A man shouted, "We're with you Jack, we're with you" while giving him a thumbs-up, and a woman sobbed.
A victim impact statement from Cooper, read to the court by the CPS, said: "I wish I could say that this planned attack on my life hasn't changed me or my life but sadly it has had a detrimental impact.
"To be informed that a stranger wished to murder you, to decapitate you, hold your staff hostage and exchange them for a police officer and after a further murder, themselves die at the hands of the police -- suicide by cop -- is something out of a horror movie, not life as I know it," the lawmaker said.
CPS Head of Counter Terrorism Division Jenny Hopkins said in a statement: "A crime of this type against anyone is a serious matter but when our MPs are targeted it is also an attack on the democratic process and public service.
"Jack Renshaw was prepared to act on his white supremacist world view and plotted to kill a Member of Parliament -- a plan reminiscent of the abhorrent murder of Jo Cox MP.
"He also made threats against a police officer and his prison sentence reflects the seriousness of the offenses."
Renshaw has been ordered to serve a minimum of 20 years in prison.
British politician Jo Cox was slain in a violent and frenzied street attack in northern England in 2016. She was shot and stabbed as she left a meeting with some of her constituents and later died as a result of her injuries.
Seen as a rising star in the opposition Labour Party, the 41-year-old was the first British lawmaker to be killed in office since Conservative MP Ian Gow was assassinated by the IRA in a 1990 car bombing.