Turkey’s Prime Minister Recep Tayyip Erdogan has claimed victory in a local election, and vowed that his enemies would “pay the price”.
Mr Erdogan’s government has been accused of authoritarianism and corruption after a string of scandals.
The local election, the first vote since mass protests last June, was seen as a barometer of his popularity.
Mr Erdogan was not standing for election but campaigned hard for his Justice and Development Party (AKP).
With about a half of the votes counted, it was leading the main opposition party 45% to 27%.
The AKP had been aiming to equal or better its 38.8% share of the vote in 2009.
AKP officials and supporters were celebrating victory long before Mr Erdogan’s announcement.
Voting in the local assembly and mayoral elections passed off peacefully in most areas, but eight people were reportedly killed in two separate incidents involving supporters of rival candidates.
Feuding families were said to have clashed in the southern city of Hatay and the eastern province of Sanliurfa.
The prime minister has been eyeing a run for the presidency in August – the first time voters will directly elect the head of state – or may seek to change the rules to allow him to seek a fourth term in office.
In the run-up to Sunday’s poll, the government blocked Twitter and YouTube, following a series of online leaks.
Mr Erdogan said social media was spreading misinformation.
On Saturday pro- and anti-government factions held rival demonstrations in Istanbul, which saw the Gezi Park protests of May and June last year.
The secular opposition Republican People’s Party (CHP) is fighting to win the Istanbul mayor’s office from Mr Erdogan’s ally Kadir Topbas. However, early results put the AKP ahead in the sprawling metropolis.
Mr Erdogan is a former mayor of the city and the vote has become an unofficial referendum on his administration. The prime minister himself has described the vote as a struggle for Turkey’s independence, our correspondent says.
The race looked tighter in the capital Ankara, with Erdogan’s party narrowly leading the CHP.
The loss of either city would be a major embarrassment for the prime minister.
“What the people say goes,” Mr Erdogan said after casting his ballot in Istanbul on Sunday. “The people’s decision is respected.”
More than 50 million people are eligible to vote, and turnout appeared to be high.
The prime minister has purged hundreds of people from the judiciary and police since several of his allies were arrested over a corruption scandal in December.
He has accused the judiciary of being behind a series of wiretaps and social media leaks allegedly exposing major corruption, and blamed the probe on a “foreign plot”.
The scandal has pitted the prime minister against a former ally, US-based Islamic scholar Fethullah Gulen, who has many supporters in the police and judiciary.
Mr Erdogan accuses Mr Gulen of using his supporters in the police and judiciary for a “dirty campaign” to try to topple him.
Mr Gulen denies the allegations but those close to the movement, known as Hizmet (“Service”), say they fear a crackdown after the elections.
The Islamist-rooted AK Party swept to power in 2002 on a platform of eradicating the corruption that blights Turkish life.
It came to power backed by a pious Muslim base looking for greater standing in a country that historically favoured a secular elite, and has ruled during a period of prosperity.
The government faced major street protests last year sparked by plans to raze Istanbul’s Gezi Park and redevelop it. The police crackdown galvanised anti-government demonstrators in several cities.
The anger which led to the unrest flared up again earlier this month, with the news of the death of a 15-year-old boy who had been in a coma since last June after being hit by a tear gas canister during a protest.