The road to democracy in Afghanistan was opened following the overthrow of the hardline Taleban regime in 2001.
Women have the vote, but have faced opposition
Western governments backed a new leader, Hamid Karzai, and promised elections to underpin efforts to rebuild the country.
Following two delays, the presidential election has now been set for 9 October. Parliamentary elections will be held separately next year.
BBC News Online takes a look at key issues.
Why must the vote be held this year?
An interim administration, headed by President Hamid Karzai, is in power until 2004.
According to the UN-brokered plan that brought Mr Karzai to power, Afghanistan's next leader must be elected by a majority in a popular vote - not appointed.
Mr Karzai must ensure nationwide presidential elections take place on time, and that they are free and fair. Afghanistan's new constitution - adopted at a grand assembly, or loya jirga, in January - sets out what shape any future government must take.
What are the logistics of the election?
Over 10.5m Afghans have registered to vote. 41.3% of the registered voters are women.
Some 400,000-600,000 Afghans refugees living in Iran are also registered, and will have 1,000 polling stations at which to cast their votes on polling day.
And in Pakistan, another 600,000-800,000 Afghan refugees are eligible to vote.
Afghans will choose from 18 presidential candidates in some 25,000 polling stations across the country. Two of the candidates said they backed Mr Karzai shortly before election day but their names remain on the ballot.
Campaigning ended 48 hours before the 9 October vote.
How is the election being made accessible to a people who have never voted in the past?
Cartoons and posters illustrate voting procedures to a largely illiterate population.
The ballot papers contain photographs, names and symbols of all the candidates to make it easier for the voters to identify their choice.
Voters mark their choice on the ballot paper with a pen.
Voters then have a thumb marked with indelible ink to prevent repeat voting.
How long will it take for the votes to be counted and the results declared?
Official say full results may take two to three weeks.
One reason is that it may take up to a week to bring the ballot boxes from remote mountainous areas to the counting centres.
But organisers will count votes as they come in and a trend may be obvious in a few days, they say.
Will Afghanistan's vote be credible?
Many have their doubts, and the UN and others have voiced concerns. There have been many calls for foreign troop numbers to be raised to bring better security - not least by President Karzai at a key Nato meeting in June.
The poll was twice postponed - first from June, and then from September. In July, officials decided not to hold a parallel parliamentary election until next April or May. They blame delays on a rising tide of violence by militants opposed to the US-backed government in Kabul.
The mounting insecurity has also hamstrung aid efforts and reconstruction work.
Because of the lack of security, there are very few election monitors - under 400. The European Union and the Organisation for Security and Cooperation in Europe have sent observer missions, but neither will issue a report on whether the election was fair.
Was violence the only hold-up?
There were fears of regional warlords and their militias who still dominate in vast swathes of the country intimidating voters on polling day.
The election is taking place in a country where tribal loyalties and religious conservatism reign supreme. Many oppose women voting, for example, and there have been a number of attacks on women voters and reports of intimidation.
How was the constitution created?
A 35-member team spent a year working on the draft constitution. Nearly half a million Afghans were asked to give their opinion on a draft version.
Public meetings were held in villages and many who were unable to write their responses had them recorded on audio.
The new constitution envisages a powerful presidency - in line with the wishes of Mr Karzai - and two vice-presidents. The office of prime minister - present in earlier versions - was dropped at the last minute, apparently to avoid creating two centres of power.
It designates Afghanistan as an Islamic republic where men and women have equal rights and duties before the law.
And Pashto and Dari are the official languages, with other minority languages to be considered "official" in areas where they are spoken.
How was it approved?
The loya jirga which comprises Afghan elders and local dignitaries met for three weeks in January 2004 and engaged in often bitter debate over the different issues.
The meeting was attended by 502 delegates - 50 nominated by the president and the rest appointed as representatives of various districts and provinces.