Former Pakistani Prime Minister Nawaz Sharif is celebrating with his supporters, amid early signs that his party will be the largest after parliamentary elections.
Media projections based on partial results suggest a big lead for Nawaz Sharif’s Muslim League, and he has already claimed victory.
The election should lead to the country’s first transition from one elected government to another.
The turnout was huge but the poll was marred by violence.
In Karachi, the Pakistan Taliban said they planted a bomb which killed 11 people and wounded 40 others.
The bomb was placed outside the office of the Awami National Party.
There were also attacks in Balochistan and the north-western city of Peshawar.
Voting was extended for an hour across the country before closing at 18:00.
An election commission spokesman said they hoped for a turnout of 60-80%. In 2008 it was 44%.
No official results have yet been released, but unofficial partial results suggested that Nawaz Sharif’s party was ahead in more than 100 of the 272 directly elected parliamentary seats.
It appears that Nawaz Sharif’s party will fall short of a simple majority in the National Assembly.
But in a speech at his party headquarters in the north-eastern city of Lahore, Nawaz Sharif said that the Muslim League (PML-N) was sure to emerge as the largest party.
“We should thank Allah that he has given PML-N [Muslim League] another chance to serve you and Pakistan.”
“I appeal for all parties to come to the table and sit with me and solve the country’s problems.”
However, the mood in the party was not one of joy, as there are so many daunting challenges facing the country.
Nawaz Sharif’s apparent victory is largely confined to his native Punjab province, which has nearly 60% of the country’s population, and so he will be compelled to look for support from the three smaller provinces for greater legitimacy.
Even if he had got as few as 90 seats he would still have been able to put together a coalition.
The prospect of Nawaz Sharif forming a new government represents a remarkable political comeback for a man deposed by General Pervez Musharraf in a coup in 1999 and subsequently put on trial and given a jail sentence.
A deal with Saudi Arabia meant he spent time in exile there before returning in 2007 to contest polls the following year.
The Movement of Justice (PTI) party of former cricketer Imran Khan has also performed well, with projections saying he had won a big victory in Peshawar.
President Asif Ali Zardari’s Pakistan People’s Party (PPP) is in a race for second place with the PTI, but both seem likely to win fewer than 40 seats.
Outgoing PM Raja Pervez Ashraf suffered a crushing defeat in his own seat in Rawalpindi.
The PPP hardly tried because of Taliban threats against it but also because of a lack of will as it was so unpopular.
The Pakistani Taliban threatened to carry out suicide attacks ahead of the election.
About two hours after polling started, a bomb attack was reported in Karachi, apparently targeting an Awami National Party (ANP) candidate outside the party’s political office.
Eleven people were killed and more than 40 others were wounded, police said. Local ANP candidate Amanullah Mahsud was injured but not seriously.
The attack happened in the Landhi district of Karachi, which is known for Taliban activity. Another ANP candidate and his son were shot dead close to the area last week.
The Taliban have been blamed for numerous attacks throughout the campaign on Pakistan’s three most prominent liberal parties.
The PPP along with the Karachi-based Muttahida Quami Movement (MQM) and the ANP have been singled out for threats, and were forced to curtail their campaigning as a result.
Although Pakistan has been under civilian rule for the past five years, the military is still believed to wield considerable power.
In what appeared to be an endorsement of democracy, Pakistan’s most powerful military officer Gen Ashfaq Parvez Kayani was filmed live on TV casting his vote in a polling booth, rather than sending it in by post as many expected.
Tens of thousands of troops had been deployed at polling stations to ensure security. In the run-up to the election, more than 100 people died in election-related violence.
Before polls opened, Pakistan sealed its borders with Iran and Afghanistan in an effort to keep foreign militants at bay. Officials said the borders would remain closed for the next three days.