California Gov. Gavin Newsom on Wednesday became the latest governor to place a statewide moratorium on executions — part of what appears to be a nationwide trend of states moving away from the death penalty, especially in the West, experts say.

Newsom, a Democrat, has called the death penalty a “failure” that discriminates against minorities and people from poor communities who cannot afford expensive legal representation.

President Donald Trump voiced opposition to the move on Twitter, citing an argument made by opponents who say Newsom’s move goes against a 2016 ballot measure Californians narrowly approved to streamline and speed up the legal process in death penalty cases by limiting appeals and expanding the pool of lawyers who are authorized to take on the cases.

Nevertheless, Newsom’s decision appears.

Here is where states stand now, and how the nation is shifting.

Where is the death penalty legal?

Capital punishment has been abolished entirely in 20 states. Another four, including California, have moratoriums in place.

Michigan was the first state to get rid of the death penalty in 1846, and Washington became the most recent state to abolish capital punishment when the state Supreme Court struck down the law last year.

Though capital punishment isn’t outlawed in most states, Texas far outpaces all other states in the number of executions it has conducted in the last 50 years. Since 1976, Texas has executed 560 people, according to The Marshall Project.

Virginia and Oklahoma have conducted the second and third-highest number of executions at 113 and 112, respectively. But even those states are performing fewer executions today than they have in the past.

People can also be given the death penalty for federal crimes, but that is more rare. The most recent federal execution took place in 2003, according to the nonprofit Death Penalty Information Center, a group that gathers and disseminates data relating to the death penalty.

How moratoriums are used

Moratoriums have traditionally been used as a way to pause the debate surrounding the death penalty and study the issue more deeply. In the past, states have created task forces or commissioned reports that they then use as fodder for reforms or for banning the practice altogether.

From 1967 to 1977, there was a nationwide de facto moratorium on the death penalty at the state level as the U.S. Supreme Court weighed in on the issue. In 1972, the court ruled the death penalty, as it was being used by the states and the federal government, was unconstitutional.

“When one third of any policy is at a dead halt, that is a strong indicator that there are very serious problems.”

But states soon changed their laws to comply with the ruling and in 1977, Utah became the first state to reimplement the policy with the execution of Gary Gilmore.

More recently, governors have begun to issue moratoriums on their own, without direction from the courts. In 2000, then-Gov. George Ryan, R-Ill., temporarily halt executions in the state. The governors of Colorado, Oregon, Pennsylvania and Washington later followed suit.

Eleven years after a moratorium was implemented in Illinois, the state legislature abolished the practice entirely in 2011. Bruce Rauner, a Republican who served one term as governor starting in 2015, proposed reinstituting the death penalty last year, but his plan has not gained traction.

In Washington state, the moratorium continued until the state Supreme Court struck down the death penalty law last year, calling it “arbitrary and racially biased.” The court’s opinion cited a number of reports that analyzed who was most likely to be sentenced to death.

With California’s decision, about a third of all death row prisoners are now in states with moratoriums.

“When one third of any policy is at a dead halt, that is a strong indicator that there are very serious problems,” said Robert Dunham, the executive director of the nonprofit Death Penalty Information Center.

Who receives the death penalty?

In California, as well as other states, there has been an increased focus in recent years on who is most affected by the death penalty.

The perpetrator is more likely to receive the death penalty in cases that involve a victim who is white. Three-quarters of the victims in all death penalty cases nationwide are white; when looking at all murder cases nationally, that number is 50 percent, according to the Death Penalty Information Center.

Minorities also disproportionately receive the death penalty. In 2016, 42 percent of prisoners on death row were black, according to a Department of Justice report, though African Americans make up about 13 percent of the total U.S. population. Of the 20 people executed nationwide in 2016, 18 were white and 2 were black.

However, nearly 95 percent of prosecutors in states where the death penalty is legal are white, according to an analysis from the Death Penalty Information Center. Ninety-eight percent of prisoners given the death penalty are male.

United Nations human rights experts have also argued that the death penalty disproportionately affects people from poorer communities because they are more likely to be targeted by police and less likely to be able to afford legal defense.

Death row cases can also clog up the prison system. California, for example, has 740 people on death row, more than twice as much as any other state. But California has only carried out 13 executions since the death penalty was reinstated in 1978 after the nationwide moratorium.

Dunham said part of the reason for the relatively low number of executions compared to the number of people on death row is the state’s shortage of public defenders who are trained for capital murder cases.

What do Americans think of the death penalty?

Public support for the death penalty has waned significantly in recent decades, according to the Pew Research Center.

In 1996, 18 percent of American opposed the death penalty for people convicted of murder, and 78 percent were in favor of it. Now, 39 percent oppose it, while 54 percent support it.

A recent Gallup poll also found about 49 percent of Americans think the death penalty is “applied fairly,” compared to 45 percent who think it is applied unfairly. About 29 percent of Americans say it is applied too often. A higher proportion — 37 percent — think it is not applied enough.

However, support for the death penalty has increased slightly in the last two years, after reaching a four-decade low in 2016.

The issue is also increasingly partisan. In 2018, 77 percent of Republicans were in favor of the death penalty, compared to just 35 percent of Democrats. In 1996, the gap was much smaller, said Jocelyn Kiley, an associate director of research at Pew. Eighty-seven percent of Republicans and 77 percent of Democrats supported the death penalty at that time.

Men are also more likely than women to favor the death penalty, as are older Americans compared to those younger than 30 years old.

What’s causing the decline in executions?

Even in states where the death penalty is still legal, lawmakers have taken steps to change who can be given the death penalty and how executions are conducted.

While some states have taken steps to encourage prosecutors to seek the death penalty for crimes against law enforcement, many other changes have made the death penalty more restrictive.

A few years ago, states began seeing a shortage of lethal injection drugs because companies and governments in Europe did not want to be associated with executions. States began using alternatives, leading to botched executions. The publicity–and public backlash–surrounding those executions led to some states passing laws that restrict which drugs can be used.

Alabama recently changed its law to prevent judges from overriding a jury and issuing the death penalty.

And while a majority of the public still supports the death penalty as an option in some instances, both judges and Americans sitting on juries appear to be less willing to recommend the death penalty in specific cases. In 2018, only 41 death sentences were given out — the fourth year with fewer than 50 sentences issued, and only a fraction of the more than 300 death penalty sentences given during the peak in the 1990s.