Washington’s Supreme Court has declared that its capital punishment is applied “in an arbitrary and racially biased manner.” (Photo: The Canadian Press)

Washington state’s Supreme Court has ruled that the death penalty is unconstitutional and converted to life in prison all pending death sentences in the state.

The court’s decision on Thursday was unanimous, with the justices determining that capital punishment is applied “in an arbitrary and racially biased manner.”

“The use of the death penalty is unequally applied — sometimes by where the crime took place, or the county of residence... or the race of the defendant,” the court said in its opinion. “The death penalty, as administered in our state, fails to serve any legitimate penological goal; thus, it violates article I, section 14 of our state constitution.”

With the ruling, 20 states have either abolished or overturned the death penalty, according to the non-profit group Death Penalty Information Center. Three others have moratoriums on it.

Washington Gov. Jay Inslee, a Democrat who imposed a moratorium on the death penalty in 2014, celebrated the ruling in a statement that called it a “hugely important moment in our pursuit for equal and fair application of justice.”

The ruling followed arguments against the death penalty on behalf of Allen Eugene Gregory, who was convicted of raping, robbing and killing 43-year-old Geneine Harshfield in 1996 in Tacoma, Washington.

The justices said they would not reconsider Gregory’s arguments on his guilt, stating that his conviction has already been appealed and affirmed by the court.

Love HuffPost? Become a founding member of HuffPost Plus today.

This article originally appeared on HuffPost.