Certain media outlets have carried reports speculating over the possibility of a military coup in Turkey, with Erdogan out of the country for almost a week on a visit to the United States.
The Turkish military has stepped in on three occasions to oust elected governments - in 1960, 1971 and 1980 - and in 1997 also forced out Erdogan's late mentor Necmettin Erbakan from the premiership.
"Discipline, unconditional obedience and a unified chain of command are the basis of the Turkish armed forces," the military said in a rare political statement on its website.
The military said it would take legal action over the reports, without specifying which ones, and complained that "such baseless news" was undermining morale in the armed forces.
Also Read
However an opinion piece written by the scholar Michael Rubin published in Newsweek entitled "Will there be a coup against Erdogan in Turkey?" had gathered major attention in and outside the country.
The army was historically considered a major force in Turkish politics, able to oust governments who it believed were eroding the secular principles of the modern republic set up by Mustafa Kemal Ataturk.
Most analysts have believed the military poses no threat to the rule of the Islamic-rooted Justice and Development Party (AKP).
The president on Tuesday left for a trip to the United States amid growing signs of a major rupture in relations between Washington and Ankara as well as controversy over press freedom in Turkey.