Israeli Prime Minister Benjamin Netanyahu has claimed a "huge win" in a vote that challenged his leadership of the Likud party.
About 49 percent of Likud's 116,000 eligible members voted on Thursday, party figures show.
Challenger Gideon Saar conceded defeat, saying he would now back Netanyahu in March's general election.
The internal party vote was seen as a test of Netanyahu's hold on power at a time of mounting difficulties.
Netanyahu, 70, faces trial on bribery and corruption charges, as well as a third national election within a year.
Previous elections held in April and September saw Likud deadlocked with the centrist Blue and White party - with neither able to form a government.
After polls closed at 11pm local time on Thursday (10am Friday NZT), Netanyahu tweeted a claim that he had won, although a result is not expected until early on Friday.
"With God and with your help, I will lead the Likud to a big victory in the upcoming elections and continue to lead the State of Israel to unprecedented achievements," he posted (in Hebrew).
Saar, a 53-year-old former minister, later conceded defeat in a tweet (in Hebrew).
"I am content with my decision to have stood. Those who are unwilling to take a risk for what they believe in will never succeed," Mr Saar wrote.
"My colleagues and I will stand behind [Netanyahu] in campaigning for the Likud's success in the general elections," he added.
Mr Saar, a well-known figure in the party, had wanted to take Likud on a new path.
Earlier on Thursday, with reports of low turnout amid bad weather, Netanyahu appeared on a Facebook Live broadcast appealing for members to get out and vote.
He was predicted to win comfortably but campaigned tirelessly because he wanted the result to show his grip on the party remained strong, the BBC's Barbara Plett Usher in Jerusalem said.
Netanyahu, who is the country's longest serving leader, is facing mounting scrutiny after being indicted in three corruption cases last month.
He denies wrongdoing and claims the charges are a politically motivated "witch-hunt" against him.
One exit poll cited by local media suggested Netanyahu had won more than 70 percent of the vote.