Afghan presidential candidate Abdullah Abdullah smiles during an interview with media in Kabul. Abdullah Abdullah and Ashraf Ghani, both seen as pro-U.S. moderates, fell short of a majority in the April 5 vote. (Shah Marai/AFP/Getty Images)

A pro-Western candidate has emerged from Afghanistan’s April 5 presidential contest with the most votes but still must compete in a runoff election, Afghan election officials said Saturday.

After three weeks of counting, the Independent Election Commission (IEC) unveiled the final results of the country’s third presidential race since the 2001 U.S.-backed invasion to dislodge the Taliban.

Abdullah Abdullah, a former foreign minister who was a top opposition leader during the tenure of outgoing President Hamid Karzai, was the leading vote-getter with 44.9 percent. Ashraf Ghani, a former finance minister and World Bank economist, came in second with 31.5 percent.

Zalmay Rassoul, widely considered Karzai’s favored candidate, received 11.5 percent of the vote.

Barring a major change when results are certified May 14, Abdullah and Ghani will move on to a second round of balloting because neither received at least 50 percent of the vote, officials said.

1 of 27 Full Screen Autoplay Close April 5, 2014 Skip Ad × RECAP: Afghan voters choose new president View Photos Voters turned out in larger numbers than expected Saturday to choose a new president to lead them into the post-American era. Caption Voters turned out in larger numbers than expected Saturday to choose a new president to lead them into the post-American era. April 6, 2014 Afghan election workers write numbers on ballot boxes at a counting center in Kabul. Mohammad Ismail/Reuters Buy Photo Wait 1 second to continue.

Both are viewed as moderate and have pledged to work with the United States to keep up the pressure on the Taliban and other militant groups. But Abdullah, who would be the first ethnic Tajik to lead Afghanistan since 1996, has been particularly open about his hope for improved ties with the United States.

Ahmad Yousuf Nuristani, the chairman of the IEC, said the runoff is tentatively slated for June 7. Yet there was uncertainty Saturday about whether Ghani will challenge the results of the April 5 contest.

Ghani adviser Hamidullah Farooqi said the results included hundreds of thousands of potentially fraudulent votes in addition to the 234,674 votes already under review by the IEC because of concerns about ballot security. He said the campaign will detail its allegations in the coming days.

Abdullah has appeared more comfortable with the prospect of a runoff. Four years ago, when he was due to meet Karzai in a runoff, he abruptly dropped out of the race to protest what he called a corrupted electoral process. Now, however, he says the runoff must take place to ensure the integrity of Afghanistan’s new democracy.

“If it goes to the second round in accordance with the rule of law, we are ready for it, and we think it will be an even more proud time for our nation,” Abdullah said in a recent interview.

Despite repeated threats from the Taliban and concerns about security, IEC officials said nearly 7 million ballots were cast, a turnout of about 60 percent. Sixty-four percent of votes came from men and 36 percent from women, the officials said.

If the runoff is held in early June, that would be good news for U.S. officials, who had worried that the process could drag on well into the summer.

Karzai, who is leaving office after two terms, has refused to sign a security agreement with the United States to allow up to 15,000 foreign troops to remain in Afghanistan after this year. Abdullah and Ghani both support the agreement, but some U.S. officials fear that a protracted campaign would complicate Pentagon planning for the post-2014 mission.

In an interview, Abdullah said he would sign the agreement immediately as part of a broader effort to form a “genuine partnership” with the United States.

He criticized Karzai for recently referring to Taliban militants as “brothers” and said the Afghan government has to do more to recognize the “sacrifices” that Afghan and coalition forces have made.

“We need this partnership, and [to] do everything from our side to strengthen and put the relationship on the right footing,” Abdullah said. “I will not hesitate to do that.”