1044 GMT April 21, 2018
The authorities declared July 15 an annual national holiday of "democracy and unity", billing the foiling of the putsch as a historic victory of Turkish democracy, AFP reported on Sunday.
In an intense program aiming to hammer home the anniversary's importance, Erdogan attended a special session of parliament in Ankara, spoke to a mass rally in Istanbul and then flew back to the capital for a rally outside parliament and a special event at the presidential palace in the early hours of the morning.
Speaking to hundreds of thousands by the bridge across the Bosphorus in Istanbul that was a fighting flashpoint, Erdogan warned Turkey could reintroduce capital punishment.
"First of all we will chop off the heads of those traitors," Erdogan said, reaffirming he would sign any passed by parliament bill on resuming executions.
Any move to restore capital punishment – which Turkey abolished in 2004 – would effectively end Ankara's European Union membership ambitions.
Erdogan also said the suspects being tried over the failed coup should wear uniform clothing like the notorious orange jumpsuits used at US military prison at Guantanamo Bay.
"When they appear in court, let's make them appear in uniform suits like in Guantanamo," Erdogan said to cheers.
Supporters chanted "we are soldiers of Tayyip (Erdogan)", with some even brandishing nooses in a symbol of their support for the death penalty.
In the later speech to thousands outside parliament in Ankara which was bombed by warplanes that night, Erdogan declaimed "our nation showed the whole world what a nation we are on July 15."
The crowds later made their way to the palace where dozens had camped outside for the final official event during which Erdogan inaugurated a monument to the victims which has people hold up the crescent and star symbols of the Turkish flag.
Two hundred and forty nine people, not including the plotters, were killed when a disgruntled faction of the army sent tanks into the streets and war planes into the sky in a bid to overthrow Erdogan after one-and-a-half decades in power.
But they were thwarted within hours as the authorities regrouped and people poured into the streets in support of Erdogan, who blamed followers of his ally-turned-nemesis, the US-based preacher Fethullah Gulen.
"Did my citizens have weapons? They had their flags like today but they had a more efficient weapon: their faith," Erdogan said in Istanbul.
In the wake of the failed coup bid, authorities embarked on the biggest purge in Turkey's history, arresting 50,000 people and sacking almost three times as many. Erdogan also shored up his position by winning a referendum on enhancing his powers earlier this year.
In the latest dismissals, another 7,563 police, soldiers and other state employees were fired late Friday under the state of emergency that has been in place since July 20 last year.
Erdogan said a decision would be made on Monday over whether to recommend extending the emergency by another three months.