A lawyer entered the plea on behalf of Majid Khan at the U.S. base in Cuba. Asked by the judge if he understood the plea, Khan answered in English "yes, sir."
Khan is the first of the so-called "high-value" detainees to plead guilty. A plea agreement caps his sentence at 25 years though he could serve less time.
His lawyers are seeking to seal the details of his deal to protect him and his family. Prosecutors say it should be open because of overwhelming public interest. A judge is expected to rule on the issue Wednesday.