Mr Humala has captured the imagination of many voters
Voters in Peru have gone to the polls to choose among 20 candidates for the presidency. As the ballots are counted, it has become clear the vote will go to a second round. What is still uncertain is which two of the three leading candidates will make it to the run-off.
With half the votes counted, former army officer Ollanta Humala has a slight lead, followed closely by pro-business ex-congresswoman Lourdes Flores and former President Alan Garcia.
Why is Mr Humala so popular?
A political unknown before launching his campaign, Mr Humala has struck a chord with poorer voters, who have seen little benefit from recent economic growth and feel let down by traditional politicians.
His promise to take a bigger bite out of foreign investors' profits, scrap the current constitution and launch a "revolution" for the poor has seen his support swell in the weeks running up to the poll, despite concerns over his lack of a firm policy programme and allegations of human rights violations during his time an army commander.
What do his critics say?
Mr Humala's plans to increase state control over the economy and restrict foreign investment have sent jitters through the financial markets and foreign investors are growing increasingly wary.
And the US is concerned by his many similarities to Venezuela's President Hugo Chavez, who has been seeking to counter US influence in the region.
Like Mr Chavez, Mr Humala has been labelled a populist and a nationalist, and like Mr Chavez he is a fierce opponent of US-style free market policies.
However, despite his plans to scrap a free trade deal with the US and legalise coca production, Mr Humala has said he is keen to pursue good relations with the US.
Who are the other candidates?
Mr Humala's main rival is Lourdes Flores, a pro-business lawyer and former congresswoman, who is hoping to emulate Michelle Bachelet's success in Chile to become Peru's first female president.
She is promising social reform based on a modern, efficient, free-market economy.
Ms Flores is popular among female voters and among Peru's middle class, and at one point was leading in the polls. However, her image as the candidate of big-business has dented her support among the poor.
The other candidate with a chance of making it through to the second round is Alan Garcia, a former president who left a legacy of hyperinflation and rebel violence.
Mr Garcia appeals to the moderate left and has worked hard to attract younger voters, many of whom will have only vague memories of his time as president. He has also been helped along by his party, the American Popular Revolutionary Alliance, the oldest in the country.
What are the main issues?
Peruvians had high hopes when Alejandro Toledo was elected president in 2001, vowing to launch a "head-on war on poverty" but, despite success in achieving sustained economic growth, his efforts to improve the living standards of the millions of poor have had little impact.
Official figures show that half the population still live below the poverty line and voters are frustrated at the slow pace of job creation
The health system is in crisis after years of underfunding and a series of doctors' strikes. Up to a quarter of the population have no access to healthcare.
Education is in urgent need of a spending boost, and many rural areas still lack access to clean drinking water and paved roads.
Voters are also looking for a clean break from the sleaze of recent years. President Toledo's time in office has been marred by a series of corruption scandals.
Observers say corruption is fuelling a growing drugs trade - Peru is now the world's second biggest cocaine producer after Colombia. Drug traffickers are believed to have formed alliances with the Maoist rebel group Shining Path, which waged a violent campaign in the 1980s to overthrow the state.
Memories of the rebel violence have re-emerged in the run-up to the polls. The Shining Path has called for a boycott of the election in the central jungle region and has threatened to sabotage the vote.
How does the electoral system work?
As well as electing a president and two vice-presidents to a five-year term, voters will elect 120 members of Congress and 15 representatives to the Andean Parliament, which is similar to the EU's European Parliament, but on a smaller scale.
If no presidential candidate wins more than 50% plus one vote in the first round, a run-off will be held in May or June between the two candidates with the most valid votes.
The winner will be inaugurated on 28 July, Peruvian Independence Day. Once sworn into office, the president will appoint a prime minister, who in turn appoints a cabinet, subject to the president's approval.
Voting is compulsory for all citizens aged 18-70. According to the national electoral office, there are approximately 16.5 million registered voters, including some 458,000 who live abroad.
BBC Monitoring selects and translates news from radio, television, press, news agencies and the internet from 150 countries in more than 70 languages. It is based in Caversham, UK, and has several bureaux abroad.