Turkey's long-standing leader Recep Tayyip Erdogan says unofficial results from the presidential elections show he has won outright in the first round.
Erdogan has 53%, while his closest rival, Muharrem Ince, is on 31%, state media report, with most votes counted.
But the opposition dispute these figures, saying many votes have yet to be counted.
Erdogan also said the governing alliance of his AK Party had secured a majority in parliament.
With 96% of the votes for parliament counted, the president's AK Party leads with 43% of the votes, the state news agency Anadolu reports. The main opposition CHP is on 23%.
Crucially, the pro-Kurdish HDP looks set to reach the 10% threshold and enter parliament. This might have made it harder for Erdogan's party and its ally the MHP to reach a majority, although currently they are on course to do so.
Voter turnout is high, at almost 87%, the state broadcaster says.
As the BBC's Mark Lowen points out, the opposition is disputing the agency's reports of how many ballot boxes have been opened:
Turkey remains under a state of emergency imposed in the aftermath of a failed coup in July 2016.
Who is standing for president?
These elections were originally scheduled for November 2019 but were brought forward by Erdogan.
He is seeking a second term as president, and would govern under a new constitution which grants the president new powers.
Erdogan was prime minister for 11 years before becoming president in 2014.
Should he win, Ince has promised to push back what he characterised as a slide into authoritarian rule under Erdogan.
But his opponent accused the former physics teacher of not having the skills to lead.
Around 60 million Turks were eligible to take part in Sunday's dual polls.
In all, there were six candidates on the presidential ballot.
If no one candidate crosses the 50% threshold in an outright win, the top two will face off in a second-round vote on 8 July.
Is the vote likely to be fair?
Security was tight at polling stations. Ahead of the vote, concerns were raised about potential voter intimidation and electoral fraud.
Turkey's election commission has already said it will investigate alleged irregularities in Urfa province, on the southern border with Syria.
Ince said he would be spending the night at the electoral commission's headquarters in Ankara to ensure a fair count.
In a tweet, he asked election observers not to leave the ballot boxes. Ince said the commission's system reports 37% of boxes have been opened, whereas Anadolu says 85% of votes have been counted.
Rights activists also say the press is not free to report on all sides.
Under Erdogan's rule, the country has become the world's biggest jailer of journalists, according to monitoring groups.
What effect will the new constitution have?
While the other candidates have rejected the changes, endorsed in a tight referendum last year by 51% of voters, Erdogan would start his second term in a turbo-charged version of the job.
The job of prime minister would be scrapped and the president would gain new powers, including the ability to directly appoint senior officials.
What have been the main election issues?
The biggest is the economy. The Turkish lira has tanked and inflation stands at around 11%.
Terrorism is another vexed issue, as Turkey faces attacks from Kurdish militants and the jihadists of the Islamic State group.
However, correspondents say the country tends to vote along its big divides: one between Kurds and nationalists, and another between religious and secular people.