BEIRUT — Saudi Arabia released Loujain al-Hathloul, one of the country's most prominent women's rights activists, from prison on Wednesday in the clearest sign yet that the kingdom's leaders were taking steps to assuage President Biden's complaints about human rights violations.

Hathloul, 31, has been among the most visible faces of an unrelenting Saudi crackdown on human rights advocates, dissidents and civil society activists. Her imprisonment, which lasted 1,001 days, and her allegations that she had been tortured, sparked an international outcry.

Her release from prison comes at a time when Saudi Arabia faces increased skepticism, if not hostility, in Washington after the election of a new president and after the Democrats won control of the Senate.

In recent weeks, the kingdom has taken several steps that could enhance its brand, including a reconciliation with its neighbor Qatar and the release of activists jailed on what human rights groups say were bogus terrorism-related charges. The most prominent of these is Hathloul, who is well known for campaigning for women’s right to drive and for the abolition of Saudi guardianship laws, which require women to obtain a male relative’s consent for major decisions, including education and travel.

On Wednesday, President Biden welcomed Hathloul’s release. “She was a powerful advocate for women’s rights, and releasing her was the right thing to do,” Biden said during remarks at the Pentagon.

A Saudi appeals court in January reduced the prison term of Walid Fitaihi, a dual U.S.-Saudi citizen who founded a prominent hospital in the kingdom. Earlier this month, two other dual citizens were released from custody, pending trial.

Despite these steps, Hathloul and others have not been acquitted by Saudi courts and remain under tight restrictions that prevent them from leaving the kingdom. Human rights activists are pressing for these constraints to be lifted entirely.

In pictures posted by her sisters Wednesday, Hathloul looked gaunt, with a thick streak of silver in her hair. Her family had previously said that she had been transferred to a secret prison and subjected to abuse, including torture, beatings, sexual harassment and electric shocks — some supervised by Saud al-Qahtani, a senior adviser to the crown prince. Saudi officials have denied reports of torturing prisoners.

A Saudi court in December had sentenced Hathloul to five years and eight months in prison but suspended a portion of her sentence and included time served, ensuring a relatively speedy release from custody — widely interpreted as a gesture to the incoming Biden administration.

For four years, Saudi Arabia benefited from having a close ally in President Donald Trump, who staunchly defended the kingdom as it was criticized for abuses. But Biden has vowed to reassess the relationship, with human rights a key component.

“For years, there has been constant pressure” on Saudi Arabia, said Taha al-Hajji, a Saudi lawyer and legal consultant for the European Saudi Organization for Human Rights (ESOHR). “Pressure on the government, pressure from [international] media, but it was relying on the Trump administration to have its back.”

“I am sure the change in the U.S. administration increased the pressure a lot,” he said.

Some of the most notable demands that Biden raised during his presidential campaign have so far gone unaddressed — including accountability for the killing of Washington Post columnist Jamal Khashoggi inside the Saudi Consulate in Istanbul and for the high number of civilian casualties caused by the Saudi-led military campaign in Yemen.

But even before Biden was inaugurated, Saudi Arabia had taken some steps welcomed internationally.

Last month, for example, Saudi Arabia agreed to reopen its borders and its airspace to Qatar after sealing them in 2017 as part of a blockade imposed by the kingdom and three other Arab countries. The rift had been the most serious in decades among the Persian Gulf monarchies, and it divided U.S. allies in the region considered crucial for confronting Iran.

As the result of negotiations, Saudi Arabia had dropped a list of 13 demands, including that Qatar cool its relations with Iran and close the popular news channel Al Jazeera, and Qatar agreed to freeze legal action it was pursuing against the kingdom, according to a person familiar with the talks, who spoke on the condition of anonymity to discuss the negotiations.

Saudi Arabia has also tightened rules governing when it applies the death penalty, a step welcomed by human rights advocates. Before the changes, the kingdom had faced international criticism for its status as a world leader in capital punishment, lagging only behind China and Iran, and because of the manner in which the punishment was meted out. Saudi Arabia generally beheads prisoners, in ceremonies performed by sword-wielding executioners. Until recently, beheadings were carried out in public squares.

Beginning in early 2020, the judiciary imposed a moratorium on the use of the death penalty for nonviolent offenses, including for drug-related crimes, which accounted for nearly 40 percent of the roughly 800 executions carried out in the kingdom over the last five years. In April, the government announced that minors would no longer face the death penalty in certain cases.

Saudi Arabia has undergone a transformation under Crown Prince Mohammed bin Salman, who became heir to the throne in 2017, and is also defense minister.

Mohammed spoke of a new Saudi Arabia, and took steps to bring that vision to life. He removed a ban on women driving, promoted job creation for Saudi nationals and began to wean the country off its dependence on oil. But throughout his tenure as the kingdom’s de facto ruler, he has also made clear that the only reforms permitted are those bequeathed by the government and that political activism of any kind would not be tolerated.

The crown prince enjoyed a warm relationship with Trump and even more so with his son-in-law, Jared Kushner, and critics of Saudi policies said that relationship earned Mohammed a pass.

During Trump’s administration, Saudi Arabia not only led an effort to blockade Qatar but also detained female activists and rounded up business executives and held them in the Ritz-Carlton in Riyadh. In October 2018, after Saudi agents killed Khashoggi — the CIA concluded that Mohammed was responsible for ordering the operation — Trump argued that the slaying should not intrude on bilateral commercial and diplomatic ties.

During a presidential debate in 2019, Biden answered yes when asked if he would punish Saudi leaders for Khashoggi’s murder, as well as for executing nonviolent offenders. “Khashoggi was in fact murdered and dismembered, and I believe [on] the order of the crown prince,” Biden said. He then said he would halt sales of weapons to Saudi Arabia.

“We were going to in fact make them pay the price, and make them in fact the pariah that they are.”

Biden added: “They’re going in and murdering children, and they’re murdering innocent people. And so they have to be held accountable.”

Last week, Biden announced an end to U.S. support for offensive operations in Yemen. The Saudi-led coalition fighting Yemeni rebels has been criticized for repeatedly striking Yemeni civilians.

The change in U.S. administration has come as Saudi Arabia is facing economic challenges because of the coronavirus outbreak and plummeting oil prices.

Kristin Smith Diwan, a senior resident scholar at the Arab Gulf States Institute in Washington, said the recent shifts in Saudi policy, such as reconciliation with Qatar, are caused by two things: “the shift in the political environment because of the new Biden administration, but also coronavirus.”

 Fahim reported from Istanbul.