None of the eight candidates who contested the first round of the election on April 5 won more than 50 percent of the vote meaning the top two contenders have to face off on Saturday.
The two men aiming to succeed President Hamid Karzai, who is constitutionally barred from a third term, are a former foreign minister, Abdullah Abdullah, and an ex-World Bank economist and former finance minister, Ashraf Ghani.
The winner will inherit an unfinished war and an economy in the doldrums.
The Taliban are still strong and Afghanistan's foreign-trained army has never put to rest questions about its effectiveness, especially in the absence of foreign troops, the bulk of whom will leave by the end of the year.
Afghanistan's economy is slowing rapidly and faces the prospect of an international blacklist later this month because of a failure to stem money laundering and terror financing.
Abdullah, a former leader in the anti-Taliban Northern Alliance, won 45 percent of the vote in April while Ghani got 31.6 percent.
But Ghani, an ethnic Pashtun, stands to gain more of the Pashtun vote that was splintered between candidates in the first round. Abdullah is part Pashtun but more closely identified with the ethnic Tajik minority.
Below is a timeline of key events and brief biographies of the contenders.
May 22 : Run-off campaign began
June 11: Campaign ended
June 14: Election day
July 2: Preliminary results announced
July 16: Complaints body submits final report
July 22: Final results announced
A former ophthalmologist-turned-fighter of Soviet forces in the 1980s, Abdullah dropped out of a run-off against Hamid Karzai in the last presidential election, in 2009, citing concern about electoral fraud.
An adviser to the assassinated Northern Alliance guerrilla leader Ahmad Shah Masood, Abdullah was appointed foreign minister in Karzai's first government after the Taliban were ousted in 2001. He was dropped from the cabinet in 2005.
Abdullah's support base lies in the ethnic Tajik community, Afghanistan's second largest ethnic group, although he is half-Pashtun.
As a young man, Abdullah studied medicine at Kabul University and worked as an ophthalmologist until 1985.
A year later he joined the Panjshir Resistance Front against the Soviet invaders and served as an adviser to Masood, a national hero for many Afghans.
Abdullah was foreign minister of the United Front - better known internationally as the Northern Alliance - from 1998 and, after Masood's assassination in 2001, became a leading figure in the alliance that helped U.S. forces topple the Taliban.
ASHRAF GHANI AHMADZAI
The American-trained anthropologist returned to Afghanistan after the Taliban were ousted and held various government posts, including finance minister. He won about four percent of the vote in the 2009 presidential election.
One of Afghanistan's best-known intellectuals, Ghani spent almost a quarter of a century abroad during the tumultuous decades of Soviet rule, civil war and the Taliban regime.
During that period he worked as an academic in the United States and Denmark, and with the World Bank and the United Nations across East and South Asia.
Within months of the Sept. 11, 2001, attacks on the United States, Ghani resigned from his international posts and returned to Afghanistan to become a senior adviser to Karzai.
Ghani is among the strongest backers of a crucial bilateral security deal to keep U.S. troops in Afghanistan beyond 2014, which Karzai has refused to endorse. Ghani has said he would sign it swiftly if elected.
A member of Afghanistan's biggest ethnic group, the Pashtuns, Ghani has defended his decision to pick Abdul Rashid Dostum, a controversial former guerrilla strongman from the minority ethnic Uzbek community, as a running mate.
"The ticket is a realistic balance between forces that have been produced in the last 30 years and have a base in this society," Ghani told Reuters.
Get Breaking news, live coverage, and Latest News from India and around the world on NDTV.com. Catch all the Live TV action on NDTV 24x7 and NDTV India. Like us on Facebook or follow us on Twitter and Instagram for latest news and live news updates.