Thousands of people took part in rallies across Turkey in an act of defiance following a failed coup against Turkish President Recep Tayyip Erdogan that was organised by rebel soldiers, leading to the deaths of 265 people, with more than 1,400 injured. Gathering at Istanbul airport, central Taksim square and outside the presidential palace, supporters waved flags and brandished placards in favour of the Turkish president.

The failed coup, which was attempted on the evening of 15 July, saw rebel soldiers use tanks, attack helicopters and fighter jets as means to try to overthrow Erodogen. They attacked the Turkish parliament, along with the intelligence agency headquarters in Ankara, while others seized a bridge and surrounded Istanbul airport.

Authorities managed to arrest roughly 2,839 military personnel – including the general of the Second Army that protects the country's borders with Syria, Iraq and Iran − in the wake of the attempted plot, according to the state-run Anadolu news agency. As many as 8,000 police have been removed from their positions across the country, including in Istanbul and the capital Ankara. According to a senior security officer, who spoke to Reuters, the removal was due to alleged links with the failed coup, which the Turkish government blames on a "parallel state" led by self-exiled Islamic preacher Fethullah Gulen.

On 17 July, funerals were held for those killed. One was was situated in the Fatih Mosque in Istanbul and was attended by Erodogen. During his funeral speech the Turkish President spoke of the possibility of reintroducing the death penalty, which was abolished in 2004, after a high demand from supporters that he said could not be ignored. However, Turkey's pro-Kurdish Peoples' Democratic Party (HDP) said that he would not support any proposal put to parliament on the reintroduction of such penalty. "No, we will not support it," Bilgen said, adding that in any case new laws could not be applied retroactively and that it was the responsibility of politicians to communicate this to the people.

Following the failed weekend coup, EU Foreign Policy Chief Federica Mogherini has warned the Turkish government that they must protect the rule of law and avoid steps that would damage the constitutional order. EU commissioner, Johannes Hahn, who is dealing with Turkey's membership bid, says the swift rounding up of judges after the coup indicates the government must have prepared a list beforehand. "We were the first, and I was personally the first, during that tragic night, to say that the legitimate institutions needed to be protected. We are the ones saying today rule of law has to be protected in the country − there is no excuse for any steps that takes the country away from that."