Turkey is headed for a runoff vote after President Tayyip Erdogan led over his opposition rival Kemal Kilicdaroglu in Sunday's election but fell short of an outright majority to extend his 20-year rule of the NATO-member country.

Neither Erdogan nor Kilicdaroglu cleared the 50% threshold needed to avoid a second round, to be held on May 28, in an election seen as a verdict on Erdogan's increasingly authoritarian path.

The presidential vote will decide not only who leads Turkey but also whether it reverts to a more secular, democratic path, how it will handle its severe cost of living crisis, and manage key relations with Russia, the Middle East, and the West.

With almost 97 percent of ballot boxes counted, Erdogan led with 49.39 percent of votes and Kilicdaroglu had 44.92 percent, according to state-owned news agency Anadolu. Turkey's High Election Board gave Erdogan 49.49 percent with 91.93 percent of ballot boxes counted.

Thousands of Erdogan voters converged on the party's headquarters in Ankara, blasting party songs from loudspeakers and waving flags.