A man accused of opening fire in a San Diego-area synagogue, killing a woman and wounding three other people, will stand trial, a judge ruled Friday.

John T. Earnest, 20, will appear in court on Oct. 3 for his arraignment on murder and attempted murder charges stemming from the April 27 shooting in the Chabad of Poway.

He will also be tried on an arson charge for a March 24 blaze at Dar-ul-Arqam Mosque, also known as the Islamic Center of Escondido.

Earnest could face the death penalty if he is convicted of murder as a hate crime. The San Diego County District Attorney’s Office has not decided whether it will pursue capital punishment.

LEADERS STRUGGLE TO MAKE SENSE OF FATAL ATTACK ON SYNAGOGUE

Defendant John Earnest listens during testimony by witness Oscar Stewart during Earnest's preliminary hearing on Thursday in San Diego. (John Gibbins/The San Diego Union-Tribune via AP, Pool)

Prosecutors allege Earnest entered the synagogue on the last day of Passover and killed  60-year-old Lori Gilbert Kaye. Kaye was shot twice and died at a hospital.

The congregation's rabbi, Yisroel Goldstein, 57, lost a finger in the shooting. Almog Peretz, 34, and his 8-year-old niece, Noya Dahan, were also injured.

On Thursday, prosecutors played a 12-minute 911 call of the gunman telling a dispatcher that he'd shot up the synagogue to save white people from Jews.

“They’re destroying our people. I’m trying to show them that we’re not going to go down without a fight,”  said the caller on the 911 recording, who identified himself as Earnest. "I’m defending our nation against the Jewish people, who are trying to destroy all white people."

This April 27 photo from surveillance video at the Chabad of Poway shows people diving for cover as a shooting unfolds. (Chabad of Poway/San Diego Superior Court via AP)

He said he would not use his weapon on responding officers.

Oscar Stewart, 51, who was present during the shooting with his wife and stepdaughter, said during the hearing that“people were falling over each other. It was chaos."

He was standing in the back of the synagogue when shots rang out, he said. An Army and Navy veteran who served two tours in Iraq, Stewart said he rushed the gunman and yelled that he was going to kill him in an effort to distract him.

He chased after the fleeing gunman and pulled back when off-duty Border Patrol agent Johnathan Morales, who was working security, fired about five shots at the assailant.

Oscar Stewart, a congregant at Chabad of Poway synagogue who confronted the gunman. (John Gibbins/The San Diego Union-Tribune via AP, Pool)

CLICK HERE TO GET THE FOX NEWS APP

Earnest was arrested a short time later. He reportedly admitted being behind the shooting and the mosque blaze two weeks earlier.

Authorities said he posted an open letter citing his hatred for Jews and his admiration for a man accused of killing 50 people in Christchurch, New Zealand, mosques in March.

The Associated Press contributed to this report.