Speaking at the presidential palace in Ankara, Recep Tayyip Erdogan vowed that "all the viruses within the armed forces will be cleansed".
The declaration could be used to extend the detention of nearly 10,000 people rounded up since the failed coup.
More than 600 schools have been closed and thousands of state workers sacked in a crackdown by the president.
(BBC News)