From the first months of Barack Obama’s eight years in office through the whole of Donald Trump’s four-year presidency, and now the first months of President Biden’s term, the same man has led the United States’ closest ally in the Middle East.

Benjamin Netanyahu’s 12-year run as Israel’s hard-right prime minister now appears to be ending, and with it a tumultuous and politically divisive chapter in U.S.-Israel relations. That has left Biden — along with lawmakers, activists and a spectrum of interest groups — scrambling to figure out what to make of Israel’s sudden change in leadership and what it means for the United States.

Some Democrats said Netanyahu’s exit could clear the political air for a shift in relations after Netanyahu’s close ties to the GOP.

“Bibi Netanyahu made a decision to try to create and exploit partisan division about Israel in the United States,” said Rep. Andy Levin (D-Mich.), using the prime minister’s nickname. “That was a horrible mistake, because support for Israel needs to be bipartisan.” He added, “I think his leaving is just a huge relief.”

Publicly, the White House insists little will change. “We have a long and abiding relationship — strategic relationship — with Israel, and that will continue to be the case no matter who is leading the country,” White House press secretary Jen Psaki said Friday.

That obscures Netanyahu’s role in starkly rewriting the terms of the U.S. relationship with Israel, and the challenge that leaves now. Biden signaled early on he would not throw himself into the Middle East peace process as his predecessors did, but the recent violence in Israel and its change in leadership could shift his calculus.

Netanyahu, who spent some of his youth in the United States and prided himself on a sophisticated understanding of Washington, curried support among evangelical Christians, distanced himself from liberal Jewish constituencies and used his close ties to Trump as a political calling card.

Now he is likely to be replaced within days by Naftali Bennett, also a hard-right figure but one who is displaying a flair for pragmatism. Bennett will oversee a narrow and potentially fragile coalition that includes an Arab party, and he has signaled he wants to take a more unifying approach than Netanyahu.

But Bennett is something of an unknown quantity in Washington. The White House could not even say Friday whether Biden has ever met him.

Republicans are responding cautiously to Netanyahu’s likely exit. Sen. Lindsey O. Graham (R-S.C.) appeared publicly with Netanyahu in Israel last week, and both grinned for the cameras. “No one has done more for Israel than you,” Netanyahu said.

Graham later publicly thanked Netanyahu, whom he called a “great friend.” But he predicted bipartisan support for Israel regardless of who is in charge.

“From our perspective, it’s not about an individual, it’s about the relationship,” Graham told reporters Tuesday in Jerusalem. He predicted that a request for $1 billion to help Israel restock its Iron Dome missile-defense system would “sail through” Congress with White House support.

Democrats, for their part, reacted with obvious relief.

“I really think Netanyahu became an impediment” to bipartisan support for Israel, said Rep. Steve Cohen (D-Tenn.). “The United States and Israel have a strong relationship, but it’s run into previously unheard-of problems in the last five years.”

Democrats in recent years have been forced to navigate an increasingly uncomfortable balance — embracing Israel while criticizing its leadership, and supporting the Jewish state while decrying its treatment of the Palestinians. While rank-and-file Democrats have become more willing to challenge Israel, Trump and Netanyahu formed an unprecedented political alliance, with the Israeli prime minister even featuring Trump on his campaign posters.

“He’s been in power, he’s clung to power, he’s machinated to stay in power for all these years, and he’s an ethno-nationalist,” Levin, a member of the House Foreign Affairs Committee, said of Netanyahu. “He is, I think, a destructive force in politics.”

Many conservatives see Netanyahu as a strong figure who took the necessary steps to defend Israel against those committed to its destruction, and they blame Biden for pressing him to de-escalate during the recent violence. Sen. Ted Cruz (R-Tex.) said during a visit to Israel last week that Biden’s handling of the Gaza conflict “shows weakness.”

In Israel, many believe that while Netanyahu’s maneuvering may have yielded dividends when Republicans were in power, Israel is now paying the price, and some analysts predict that Bennett will try to restore some balance.

“Netanyahu worked magic in Washington, but there is no question that he identified himself so much with the Republican Party that he has a big hand in turning many Democrats to what some people might call less pro-Israel,” said Shira Efron, an Israeli scholar at Rand Corp. and the Israel Policy Forum. “The erosion of the bipartisan support for Israel is on his name.”

Biden is in many ways emblematic of the shift in Democratic politics, having entered politics amid a tradition of powerful bipartisan support for Israel. He joined the Senate not long after the 1967 war that gave Israel control over millions of Palestinians, at a time when the prime minister was Golda Meir, a charismatic American-educated socialist.

The current Democratic split was on vivid display during the Gaza conflict, when Biden faced pressure from mostly younger, more liberal Democrats critical of what they called Israel’s disproportionate use of force. They urged Biden to lean harder on Israel to end the fighting and reduce civilian casualties.

Biden was initially reluctant to publicly pressure Netanyahu. But he seemed struck by the depth of many Democrats’ anger at Israel as activists adopted the language of the Black Lives Matter movement, and eventually he bluntly urged Netanyahu to step back.

“I think that, you know, my party still supports Israel,” he said last month after the cease-fire. “Let’s get something straight here: Until the region says unequivocally they acknowledge the right of Israel to exist as an independent Jewish state, there will be no peace.”

Still, Biden has sought to return the United States to a more neutral stance after the Trump era. Even before Netanyahu’s fall, Biden restored aid for Palestinians, and in an apparent snub he waited weeks before holding his first phone call with the prime minister.

Although Netanyahu’s political troubles had mounted in recent years, he had a long record of shrewd survival, and many in Washington predicted he could somehow hang on. That looks less likely now; unless Netanyahu succeeds in derailing a recent coalition agreement, a new government could become final next week.

Bennett is hardly a dove — he opposes a fully independent Palestinian state in the West Bank and has advocated Israeli annexation of part of that occupied territory. But he would govern atop a hodgepodge of mostly centrists united around the premise that Netanyahu must go, and he is slated to cede the prime ministership in two years to the more moderate Yair Lapid.

That could make it hard for Bennett to take too many hard-line actions that would anger Washington, said Jeremy Ben-Ami, president of the liberal pro-Israel advocacy group J Street.

“Bibi Netanyahu had the stature and the confidence to publicly take on the president of the United States on his home turf and oppose what he wanted to do” on Iran, Ben-Ami said. “To use a technical term, that required a lot of chutzpah.”

While the new Israeli government also opposes the Iran deal, its leaders are unlikely to actively undermine it in the United States in the same way, Ben-Ami added.

On Thursday, Israeli Defense Minister Benny Gantz was in Washington for previously scheduled meetings on Israel’s request for aid to help replenish its missile-defense system after the Gaza conflict. He suggested a shift is already underway in how Israel would air its differences with the United States over Iran.

“We will continue this important strategic dialogue in private discussion . . . not in the media in a provoking way,” Gantz said at the Pentagon.

Secretary of State Antony Blinken did not mention Israel’s leadership change in brief remarks welcoming Gantz, who is slated to continue in his role under the new government.

But while in Jerusalem recently, Blinken made a point of meeting with Lapid, the centrist who led the efforts to remove Netanyahu, a gesture that many read as a sign that the Biden administration thought Netanyahu’s days might be numbered. Lapid and Bennett announced their partnership shortly afterward.

Blinken’s visit to Israel was followed last week by separate visits from Graham, Cruz and other Republicans eager to demonstrate their support for Israel in the wake of the Gaza conflict. All were warmly welcomed by Netanyahu.

The deep policy splits between Bennett and Lapid, as well as the rest of their diverse coalition, mean the new government will probably be fragile and inward-focused, diplomats and analysts said. Bennett may have little interest in picking fights with Biden and appears eager to restore a more bipartisan framework, most agreed.

“It’s going to be a government that’s in disagreement on everything — it’s going to be dysfunctional” and probably short-lived, said one diplomat who is watching the developments closely.

“The main thing when it comes to the U.S. is to go back to the bipartisanship and not be purposely partisan like Netanyahu, not alienating,” said the diplomat, who spoke on the condition of anonymity to discuss the sensitive matter candidly. “Bennett, he understands that. He’s more pragmatic than people tend to think.”

Cohen said the transfer of power clearly provides an opening. Asked whether the emerging government’s divisions will prevent it from agreeing on much beyond ousting Netanyahu, Cohen said that might be the case — but that it also might be enough.

He added, “The Lord works in mysterious ways.”

Sean Sullivan contributed to this report.