Image source, NurPhotoImage caption, Mass protest which started in late 2019 left the country paralysed for months
Chile was long held up as a model of political stability and economic growth in South America.
But that image was shattered when violent anti-government protests began to spread though the country in late 2019.
In the first general election since, voters face a choice between sharply diverging political visions for the future.
The leading candidates reflect the social tensions and political polarisation that have gripped the nation as a result of that internal upheaval.
This situation has been exacerbated by the social and economic strains of the Covid-19 pandemic.
The most recent opinion polls show far-right candidate José Antonio Kast in the lead, followed by left-wing former student leader Gabriel Boric.
Image source, Getty ImagesImage caption, If elected, Gabriel Boric would become the youngest Chilean president
With a total of seven candidates in the running for the presidency, it is unlikely that any one candidate will get the 50% of the votes necessary to win outright in the first round.
A second round scheduled for 19 December is therefore looking highly likely.
Besides choosing a new president, Chileans will also be electing a new 155-member Chamber of Deputies and 27 members of the 50-seat Senate, as well as regional councillors.
Divisions and anger
The election is being held at a time when Chile's political scene is unusually agitated and with the deep-rooted anger displayed during the anti-government protests of 2019 and 2020 still raw.
One of the demands made by the protesters was for a new constitution to replace the one which dates back to the military rule of Gen Augusto Pinochet.
A Constitutional Convention elected in May 2021 and installed in July has started work on drafting a new document.
- From poverty to PhD to writing a constitution
- Chile picks independents to write new constitution
- Our voices must be heard too, Chile indigenous say
Among the changes being considered are including specific guarantees of indigenous and gender rights to access to natural resources.
All of these have fed into the presidential election campaign, provoking debate and in some cases controversy.
Outgoing President Sebastián Piñera is not standing in Sunday's election but whoever succeeds him will have to deal with the security situation in the southern La Araucanía region, where indigenous Mapuche activists have been waging a long battle for ancestral land rights.
Image source, EPAImage caption, The declaration of a state of emergency has proven controversial
President Piñera declared a state of emergency in four of the worst-hit provinces on 12 October following increased arson incidents and shooting attacks against police and residents.
Front runners and their proposals
The most recent opinion polls have 55-year-old José Antonio Kast in the lead, followed by 35-year-old Gabriel Boric.
Image source, ReutersImage caption, José Antonio Kast has been leading in the polls
The race for third place is expected to be a close one between right-leaning Franco Parisi, centre-left candidate Yasna Provoste and Sebastian Sichel, the centre-right candidate of the governing "Chile Podemos Mas" coalition.
His critics have branded Mr Kast as an "ultra-right supporter of dictatorship" because of his sympathetic comments for the rule of the late General Pinochet, who seized power in a military coup in 1973.
Others are comparing Mr Kast to Brazil's far-right president, Jair Bolsonaro.
Mr Kast has been critical of the rewriting of the constitution and has also presented himself as tough on law and order, calling for a stronger response to illegal immigration and to the violence in La Araucanía.
Analysts say this has resonated with many Chileans who were frightened by the scenes of anarchic protest and chaotic looting that accompanied the 2019 unrest.
In contrast, Gabriel Boric's youth and his moderate left-wing stance is proving attractive to Chileans who favour the idea of progressive reforms and a new constitution.
Mr Boric's economic proposals include plans to increase the state's role, replace the private pension system with a public alternative, boost taxes on big companies and wealthy individuals, and bolster state spending on social services like health insurance.
Some local analysts have presented the upcoming electoral contest as a "generational war", with the older Mr Kast appealing to middle-aged and older voters, while Mr Boric was seen wooing the younger vote.
"Candidates are talking to different generations," the director of the Criteria polling agency Cristian Valdivieso said.
However, surveys also showed Mr Kast's supporters were also mostly from lower socio-economic sectors and from non-metropolitan regions, while Mr Boric's backers mostly came from the middle and higher economic classes.