Security operatives of the Department of State Services, alongside court officials, asked reporters to leave just moments before the presiding judge, Justice Joyce Abdulmalik, entered the court.
An unnamed court official informed journalists that the instruction came from the judge, while a DSS officer said further clarification would be provided later.
The journalists complied with the directive and vacated the courtroom shortly after.
Media personnel from various organisations had gathered at the court as early as 8:00 a.m., but were forced out around 9:07 a.m. following the order.
The restriction comes amid strong public interest in the case involving the six defendants, who were arraigned last Wednesday by the Federal Government over an alleged failed coup attempt.
Those facing trial include retired major-general Mohammed Ibrahim Gana, retired navy captain Erasmus Victor, police inspector Ahmed Ibrahim, and Zekeri Umoru, an electrician at the Presidential Villa.
Others are Bukar Goni and Abdulkadir Sani, an Islamic cleric based in Zaria.
The defendants are facing a 13-count charge, including allegations of treason, terrorism, failure to disclose information, and money laundering. They all pleaded not guilty.
After their arraignment, Justice Abdulmalik ordered an expedited hearing and scheduled April 27 to consider their bail applications. She also directed that they be remanded in DSS custody.
Meanwhile, former Bayelsa State Governor Timipre Sylva was named in seven of the 13 charges but has not been listed as a defendant, as he remains at large.
Earlier reports indicated that about 40 individuals, comprising serving and retired military personnel as well as civilians, were arrested in connection with the alleged plot.
Out of the total, 36 serving officers have been arraigned before a court-martial convened at the Guards Brigade Scorpion Mess in Asokoro, Abuja.

