Sri Lanka's President, Mahinda Rajapaksa, has admitted defeat in his bid for a third term. His rival was his former health minister Maithripala Sirisena. Rajapaksa had called the election early in the expectation that division among the opposition would mean he would comfortably be re-elected. Instead Mr Sirisena managed to unite it and Rajapaksa has conceded despite the official results not being declared.
Key to Mr Sirisena's victory appears to be his support among the Tamils in NE Sri Lanka and the corruption of President Rajapaksa and his family.
The Tamils faced suppression of their language after independence from Britain. In 1956 Sinhala, the language of the majority Sinhalese and spoken by about 70% was made the sole official language. Large numbers of Tamils who worked for the government were forced to resign after failing to meet this language requirement. This eventually sparked an independence movement for the Tamil areas. Their fighters were the Tamil Tigers (the LTTE) who invented the suicide bomb. After a couple of decades of open fighting, the Sinhalese government retook the whole of the island amid allegations against both sides of war crimes and crimes against humanity.
By the late 1990s, the LTTE (the rebels) occupied 70 percent of northern and eastern Tamil areas. Yet by spring 2009, the LTTE was near defeat. The fighting had shrunk to a three-square-mile of LTTE-controlled land. The heightening intensity of the fighting, however, came at a high cost to civilians. The United Nations reported in April that 115,000 people had been able to escape that war zone, but 50,000 people remained trapped.
In May 2009, Government forces re-conquered all rebel-held territory. On May 19, 2009, the government formally declared an end to the decades-long civil war after the LTTE leader was killed. There are competing accounts of the death, whether he was killed directly by the government or died in battle.
In April 2014 the Canadian government suspended payments to the Commonwealth while the chair of the secretariat was held by a Sri Lankan, in protest at the country's human rights record.
The election was mostly peaceful and free of the violence and deaths common to previous polls:
Turnout in many areas was above 70%, roughly in line with previous elections, with no reports of major incidents disrupting the voting process.
In Jaffna and Trincomalee, two of the main Tamil strongholds expected to vote against Mr Rajapaksa, turnout was higher than previous national elections.
The build-up to Sri Lankan elections is usually blighted by dozens of deaths, but this year just one election-related death was reported.
Mr Rajapaksa was last elected in 2010 when he defeated his former army chief Sarath Fonseka, who was later jailed on charges of implicating the government in war crimes.
In early results, Mr Sirisena had
56.5% of the votes counted.
Al Jazeera's Charles Stratford, reporting from Colombo, said no-one had expected the margin to be so great.
"It is frankly incredible news from Sri Lanka this morning, the country waking up to a new political leader," he said.
"It seems as if they have voted for political change in this country that has seen a leader lead this country for more than ten years."
Sirisena, a former government minister who deserted the president and changed sides to become the opposition's candidate in November, has vowed to root out corruption and bring constitutional reforms to weaken the power of the presidency.