Israelis voted Tuesday in an unprecedented repeat election that will decide whether longtime Prime Minister Benjamin Netanyahu stays in power, despite a likely indictment on corruption charges.

Netanyahu, the longest-serving leader in Israeli history, is seeking a fourth consecutive term in office, and fifth overall. But he faces a stiff challenge from retired military chief Benny Gantz, whose centrist Blue and White party is running even with Netanyahu's Likud. Both parties could struggle to form a majority coalition with smaller allies, though, forcing them into a potential unity government.

Throughout an abbreviated but alarmist campaign characterized by mudslinging and slogans condemned as racist, Netanyahu has tried to portray himself as a seasoned statesman who is uniquely qualified to lead the country through challenging times. Gantz has tried to paint Netanyahu as divisive and scandal-plagued, offering himself as a calming influence and honest alternative.

After casting his ballot in Jerusalem, Netanyahu predicted the vote would be "very close."

NETANYAHU SAYS IF REELECTED HE'LL ANNEX PARTS OF HEBRON IN THE WEST BANK

"It's not in the bag. But if you go (vote), we will win," Netanyahu blared through a megaphone to shoppers at a Jerusalem market, after stopping at other Likud strongholds in the city.

Voting in his hometown of Rosh Haayin in central Israel, Gantz urged all Israelis to hope. "We will bring hope, we will bring change, without corruption, without extremism," he said.

The election marks their second showdown of the year after drawing even in the previous one in April.

At the time, Netanyahu appeared to have won another term, with his traditional allies of nationalist and ultra-religious Jewish parties controlling a parliamentary majority.

But Avigdor Lieberman, his mercurial ally-turned-rival, refused to join the new coalition, citing excessive influence it granted the ultra-Orthodox Jewish parties. Without a parliamentary majority, Netanyahu dissolved parliament and called a new election.

TRUMP SAYS HE AND NETANYAHU DISCUSSED POSSIBLE US-ISRAELI DEFENSE TREATY

Opinion polls have forecast similar results this time, potentially putting Lieberman once again in the role of kingmaker.

After voting, Lieberman reiterated his promise to force a secular unity government between Likud and Blue and White. He vowed there won't be a third election and said the parties will have to deal with the "constellation" that emerges from this vote.

The performance by the Soviet-born politician's Yisrael Beitenu party is just one of the factors that could determine Netanyahu's future. Several small parties are fighting to squeak past the minimum 3.25 percent threshold for entering parliament. The performances of these parties could make or break Netanyahu's ability to form a coalition.

Netanyahu is desperate to secure a narrow 61-seat majority in parliament with his hard-line religious and nationalist allies, who are expected to approve legislation that would grant him immunity from prosecution.

Israel's attorney general has recommended pressing criminal charges against Netanyahu in three separate corruption cases, pending a long delayed pre-trial hearing scheduled next month. Without immunity, Netanyahu would be under heavy pressure to step aside.

With his career on the line, Netanyahu has campaigned furiously and taken a late hard turn to the right in hopes of rallying his nationalist base.

He made a flurry of media appearances to beseech supporters to vote in large numbers to stave off the prospect of a left-wing government he says will endanger Israel's security. He also has accused his opponents of conspiring with Arab politicians to "steal" the election, a message that has drawn accusations of racism and incitement.

In his attacks on Arabs, Netanyahu has made unfounded claims of fraud in Arab voting areas and unsuccessfully pushed for legislation to place cameras in polling stations on election day.

After Netanyahu's proposal, seen as an attempt to intimidate Arab voters, was rejected, election officials barred cameras, including journalists, from all polling stations. In several cases, police blocked news photographers from approaching the stations.

Heavier turnout by Arab voters, many of whom stayed home in April, could hurt Netanyahu. After casting his ballot, the leader of the main Arab faction in parliament, Ayman Odeh, said Netanyahu was "obsessive" in his incitement toward Arabs. He said the answer was that his constituents "must be first-class voters on the way to becoming first-class citizens."

Facebook on Tuesday punished Netanyahu's page for the second time during the campaign, suspending his automated chat function until voting ends after it illegally published an opinion poll in the days before the election. Last week, the account was briefly suspended after a post claimed that Arabs want to "annihilate all of us."

NETANYAHU SAYS HE SOUGHT TO ANNEX JORDAN VALLEY BEFORE ELECTION BUT ISRAEL'S AG HALTED MOVE: REPORT

The page and the chatbot were posting aggressively Tuesday, with numerous videos of Netanyahu pleading with voters to turn out.

Turnout has emerged as a key element for this election day, which is a national holiday aimed at encouraging participation. In April, turnout was about 69 percent, slightly below the 72 percent figure in a 2015 election.

As of 2 p.m., Israel's central election committee said 36.5 percent of eligible voters had cast their ballots. It marked a slight increase over the figure at the same time in April.

A centerpiece of Netanyahu's eleventh-hour agenda has been the pledge to extend Israeli sovereignty over parts of the West Bank and to annex all the Jewish settlements there, something Netanyahu has refrained from doing during his decade-plus in power because of the far-reaching diplomatic repercussions.

His proposal sparked a cascade of international condemnation, including from Europe and Saudi Arabia, an influential Arab country that has quiet, unofficial ties with Israel. Jordan's King Abdullah II said Tuesday the proposed annexation would be a "disaster" for the region.

The U.S., however, had a muted reaction, suggesting Netanyahu coordinated his plan with the Americans ahead of time.

Netanyahu has also been flaunting his close ties to President Donald Trump, who has promised to unveil a peace plan after the election.

Trump chimed in with his prediction, telling reporters at the White House on Monday that it "will be a very interesting outcome. It's gonna be close."

Netanyahu also claimed to have located a previously unknown Iranian nuclear weapons facility and said another war against Gaza militants is probably inevitable. In some of his TV interviews, the typically reserved Netanyahu has raised his voice and gestured wildly as he warned of his imminent demise.

Yohanan Plesner, president of the nonpartisan Israel Democracy Institute think tank and a former lawmaker, said he didn't think it reflected genuine panic.

"I think you're observing Israel's most seasoned and competent politician who knows exactly how to fire up his base and is now using all his tools at his disposal in order to ensure victory," he said.

CLICK HERE FOR THE FOX NEWS APP

Balloting began at 7 a.m. with exit polls expected at the end of the voting day at 10 p.m. Official results are projected to come in overnight.