(CNN) President Donald Trump is celebrating Benjamin Netanyahu's Israeli election victory like it's his own -- and in many ways, it is.

Trump and his foreign policy team orchestrated one of the most undisguised US interventions in an election abroad of recent times, helping to win the Israeli Prime Minister a fifth term

Now he's claiming some of the spoils.

"Trump flags being waived at the Bibi @Netanyahu VICTORY celebration last night!" Trump tweeted before calling his friend to congratulate him on Wednesday.

Netanyahu's main opponent, Benny Gantz, leader of the Blue and White Party, conceded the election on Wednesday. Barring any stunning results in the remaining votes to be counted, the veteran Prime Minister will begin the task of building a new governing coalition next week.

Trump didn't wait for the formalities, saying on Wednesday morning that Netanyahu, leader of the Likud Party, was a "great ally" and a "friend" and that he heard the Prime Minister "won it in good fashion."

The bond between the President and the Prime Minister -- two instinctive, predatory politicians -- has clear benefits for them both. While Trump is spontaneous and impulsive, his embrace of Netanyahu shows the savvy that he brings to his own electoral positioning; Netanyahu's embrace of Trump is strategic and calculated.

Netanyahu hugged Trump close during a tight election campaign, which featured huge posters on buildings of both men in downtown Tel Aviv.

Netanyahu argued that his experience and being in lockstep with Trump fulfilled the wish list of his right-wing coalition and ultimately made Israel more safe. Those steps included the US relocation of its embassy from Tel Aviv to Jerusalem last year, and Trump's recognition of Israeli sovereignty over the Golan Heights , which it had seized from Syria in the Six-Day War in 1967. The latter came in the weeks before the election. With no pressing need for the recognition, it came across as a blatant political gift to Netanyahu -- one of many in the closing days of the campaign.

In many ways, the leaders, each prone to tough talk, reviling Iran and a willingness to embrace near demagogic campaign tactics and to infringe on campaign taboos over race, are political soulmates.

It doesn't hurt that both harbor deep disdain for Trump's predecessor President Barack Obama, who pressured Netanyahu on the Palestinian issue and made a nuclear deal with Iran.

A tale of two campaigns

JUST WATCHED Trump hands Netanyahu a victory before election Replay More Videos ... MUST WATCH Trump hands Netanyahu a victory before election 02:48

Both men will be sure to draw lessons from the last few weeks of intense campaigning in Israel.

Netanyahu succeeded partly with a sharp shift to the right in the waning days of the campaign and adopted divide-and-rule scare tactics that Trump had already perfected in his own election win in 2016. Afraid of losing out on right-wing votes, Netanyahu also courted a far-right party with extremist elements decried as racist.

Now Netanyahu has laid a road map for how a scandal-tainted leader under existential threat from political and criminal probes can ride a scorched-earth strategy to win re-election.

Trump has shown over his two years in power that he is largely motivated by his own political imperatives and above all bolstering the conservative base he needs to win re-election.

Helping Netanyahu is good politics for him, too.

Relocating the US Embassy and recognizing Israeli sovereignty over the Golan play especially well with evangelical voters, who Trump is always looking to reward.

So as a political matter, the President can judge his clear attempt to put a finger on scales of Israeli democracy a success that will keep delivering into the 2020 election in the US.

Such sharp shifts in US foreign policy also satisfy hard-line elements in the conservative national security establishment who have long agitated for an a tougher US stance against the Palestinians.

Supporters argue that the regional threats to Israel and what they see as feckless Palestinian leadership have in themselves dampened peace negotiations and require a change to US policy positions that have endured for decades.

Secretary of State Mike Pompeo argued in a congressional hearing on Tuesday that Presidents George H.W. Bush, Bill Clinton, George W. Bush and Obama had pursued policies that "didn't solve this problem."

Standing firm with Netanyahu also plays into the Trump administration's goals of betting big on one side in the Middle East -- on Sunni states including Saudi Arabia alongside Israel -- as part of its top priority of isolating Iran.

Long-term implications

JUST WATCHED Netanyahu channeling Trump amid corruption charges Replay More Videos ... MUST WATCH Netanyahu channeling Trump amid corruption charges 02:06

But Trump's willingness to shape US foreign policy for his own political ends -- evident all over the globe, not just in the Middle East -- comes with potential long-term complications for the US.

There is the risk that, by aligning the US so closely with one side of the political aisle in Israel, Trump will diminish American leverage if Israel's recent shift to the right takes a moderate reversal.

That may not concern Trump much, since he rarely seems to look that far ahead and a full four-year term for Netanyahu would stretch deep into his own second mandate if he wins reelection.

But Trump is also taking significant policy steps -- avoided by previous pro-Israel and other Republican presidents -- that could box in his successors for decades.

While the relocation of the embassy may not have caused the firestorm across the Arab world of which Trump was warned, it did prejudge the outcome of any future Israeli peace talks with the Palestinians, who see East Jerusalem as their future capital.

On its own, the embassy decision is likely to cost the US a role as a pro-Israel but third-party broker in peace talks with the Palestinians, which previous administrations played.

Just before the Israeli election on Tuesday, Netanyahu indicated that he may be willing to extend Israeli sovereignty to Jewish settlements in the Israeli-occupied West Bank, including isolated settlements deep in the Palestinian territory, in an apparent bid to shore up his right flank.

Such a move would create new realities on the map even before talks on a peace "deal of the century" that the Trump administration wants to hold. It would also likely end any faint hopes of a two-state solution in the Middle East, nearly 30 years after the Oslo Accords.

Pompeo declined to criticize Netanyahu over his West Bank aspirations and did not openly advocate a two-state solution in congressional hearings on Tuesday and Wednesday.

His silence will not have gone unnoticed in the Arab world -- nations such as Saudi Arabia, which is crucial to the yet-to-be revealed peace plan and Trump's wider Middle East aspirations.

Trump's designation this week of Iran's Islamic Revolutionary Guard Corps as a terrorist organization -- another Netanyahu goal -- represents another tectonic shift in US foreign policy. It could expose US troops in vulnerable terrain, such as Iraq, to retaliation from pro-Iranian militia forces.

The move also narrows any hope a future President may have of reentering dialogue with Iran -- perhaps to shore up the international nuclear pact from which Trump withdrew.

Not all smooth going

JUST WATCHED Trump: We have to do what's right at border Replay More Videos ... MUST WATCH Trump: We have to do what's right at border 02:26

Politics in Israel, like in the US, is never static. Even if Netanyahu succeeds in framing a new coalition, there is a strong possibility that it will not all be smooth going in relations with the White House.

Potential coalition partners are sure to seek to nail down the Prime Minister on his promise of annexing territory in the West Bank. But if he complies, he is sure to outrage regional political sentiment, which will make it tough for Arab leaders to back the Trump peace plan.

And even a US strategy that is weighted heavily against the Palestinians could cause political ripples in Israel.

"I do think whatever the Trump administration would put forward in a peace plan -- even if it would be very much skewed to the likes of Likud -- could cause a problem with Netanyahu's other right-wing coalition partners," said Michelle Dunne, senior associate with the Middle East Program at the Carnegie Endowment.

Dunne told CNN's Christiane Amanpour that Netanyahu may prefer Trump to continue taking unilateral actions that favor Israel, rather than to push a broad peace plan.

Trump, who is looking for big political wins at home and abroad, however, seems convinced that with Netanyahu now safe, he may be more ready to embrace a deal, even if it is, as many experts believe, dead on arrival due to Palestinian opposition.

"I think we now have a better chance with Bibi having won," said Trump on the South Lawn of the White House on Wednesday. It may or may not have been a coincidence that he was wearing a light blue tie and a white shirt, the colors of the Israeli flag.

US political reverberations

JUST WATCHED Trump peace plan imminent after Netanyahu win Replay More Videos ... MUST WATCH Trump peace plan imminent after Netanyahu win 07:25

Netanyahu's survival will also have a wide impact on politics in Washington, where support for Israel has been almost universal and one of the few areas of genuine bipartisanship.

But Trump's embrace of the Likud Prime Minister in his march to the far right and his attempt to brand any criticism of Israel as anti-Semitic could have significant consequences in the US and even for the Israel itself in the long term.

Sen. Chris Van Hollen, D-Maryland, confronted Pompeo on this question in a Wednesday hearing, forcing the secretary of state to agree with his point: "You can be pro-Israel ... if you don't agree with all the policies of the Netanyahu government."

Politically, the President appears to be seeking to break the Democratic stranglehold on the Jewish vote, which is especially significant in swing states, such as Florida, which will be in play in 2020.

Yet there is no sign that vote is slipping: According to a nationwide CNN exit poll, Jewish voters went 79% for Democrats in the 2018 midterm elections, and their vote typically is not solely dictated by Israeli issues.

This raises the possibility that support for Israel -- or at least its government -- could become a more partisan affair in Washington that over many years could end up harming the interests of the Jewish state.

If Democrats beat Trump next year, the incoming President may be initially cool to Netanyahu given his bromance with the current US President, leaving the Israeli leader, a dextrous operator who has proved he's willing to play politics in Washington, with work to do.