An Israeli court has handed down a life sentence to the ringleader of a Jewish gang who kidnapped, attacked and burned alive a Palestinian teenager in 2014.

Yosef Haim Ben-David, 31, was handed a life sentence for killing 16-year-old Mohammed Abu Khdeir and was given a separate 20-year sentence for other crimes.

Prosecutors said that he organised the killing of Khdeir. The court also ordered him to pay 150,000 shekels ($39,000) to Abu Khdeir's family.

Two other Jewish youth who helped him abduct Khdeir were sentenced in February, one to life in prison and the other to a 21-year term.

All three defendants had earlier confessed and said that the murder was revenge for the killing days earlier of three Israeli youths by Hamas, the Palestinian group, in the occupied West Bank.

Al Jazeera's Mohammed Jamjoom, reporting from West Jerusalem, said the verdict did not come as a surprise even though it had taken quite a long time to reach.

"It was a high-profile case and it took a long time for it to get to this point. The trial was very much in the focus of the media and rights groups," he said.

"Even though the judgment gave a closure to the case and the family, Ben-David still has the right to appeal."

READ MORE: Abu Khdeir - 'It is like Mohammed is being burned again'

Members of Abu Khdeir's family cursed Ben-David as he was taken away from court.

Ben-David, wearing a burgundy yarmulke and a black shirt, earlier told the court he was "sorry".

"I am sorry for the family. This is not me. I wasn't in control," he said.

Ben-David, 30, lodged an insanity plea that held up his formal conviction and sentencing.

After receiving psychological assessments, the court ruled he "fully understood his actions" and found him guilty.