Two New Jersey men were sentenced Friday to 35 years in prison after having been convicted of dozens of terror offenses committed at Jewish communities in the north of the state, according to website Northern Jersey.

Between 2011 and 2012, Aakash Dalal and Anthony Graziano from Lodi, NJ, tried to burn down two synagogues in the cities of Paramus and Rutherford, threw Molotov cocktails into the home of a rabbi in Rutherford, and spray-painted anti-Semitic graffiti at synagogues in the cities of Maywood and Hackensack.

Both men were 19 at the time the crimes were committed.

They were indicted in 2013. Dalal was convicted of terrorism and 16 other counts in November 2016, while Graziano was convicted of terrorism and 19 other counts in May 2017.

Graziano and Dalal in court (Photo: AP)

Dalal, a former student at Rutgers University, was charged as the "mastermind" behind the attacks who instructed his childhood friend, Graziano, to carry them out but did not commit them himself.

Brian Sinclair, an assistant Bergen County prosecutor, said the two were sentenced together as they worked together in complete cooperation.

"They were partners in hate. Partners in intimidation and ultimately in crime," Sinclair said.

"They saw the world with the same set of eyes. They saw Jewish people not as people but as subhuman and like reptiles," he added.

Graziano threw a Molotov cocktail into the Congregation Beth El temple in Rutherford on January 11, 2012, while Rabbi Nosson Schuman, his wife and five children slept in the apartment upstairs. The family members suffered light burns.

Graziano and Dalal also vandalized synagogues in Hackensack and Maywood in 2011, drawing swastikas and writing "Jews did 9/11."

Graziano apologized to the Jewish community at the sentencing, asking for leniency. "I want a second chance to live a law-abiding life," he said.

His lawyer presented him as a victim of brainwashing by Dalal, who told Graziano in one chat message: "I don't trust you until you kill a Jew."