US Attorney General Eric Holder: "We will pursue the maximum punishment"
The alleged 9/11 mastermind will be transferred from Guantanamo to New York for a trial in which the death penalty will be sought, the US has confirmed.
Khalid Sheikh Mohammed and four others would be tried in a civilian court near Ground Zero, the attorney general said.
Five other Guantanamo detainees would face military trials, Eric Holder said.
The move is part of US President Barack Obama's efforts to close Guantanamo, but some relatives of 9/11 victims say they oppose a federal court trial.
"Today I am announcing that the Department of Justice will pursue prosecution in federal court of the five individuals accused of conspiring to commit the 9/11 attacks," Mr Holder told a news conference.
I am absolutely convinced that Khalid Sheikh Mohammed will be subjected to the most exacting demands of
"I fully expect to direct prosecutors to seek the death penalty against each of the alleged 9/11 conspirators."
Four men - the two Yemenis, a Saudi and a Pakistani-born Kuwaiti - will face trial alongside Khalid Sheikh Mohammed, accused of helping finance and plan the attacks of 11 September 2001 in which nearly 3,000 people were killed.
Responsibility for the case will go to the Southern District of New York, with proceedings taking place at a court not far from where the Twin Towers of the World Trade Center fell.
New York City Mayor Michael Bloomberg said: "It is fitting that 9/11 suspects face justice near the World Trade Center site where so many New Yorkers were murdered."
No date was given for a trial, but US media reports say Congress needs at least 45 days' notice before the detainees can be transferred to the US.
Paul Reynolds, BBC World Affairs correspondent
The decision to prosecute in a federal court is a major step towards President Obama's target of closing Guantanamo by 22 January. However, problems remain.
About 70 prisoners are in limbo. There is not enough useable evidence for a military or a civilian trial yet no other country will so far take them and release is seen as too dangerous.
Guantanamo Bay, as the attorney general indicated, is therefore unlikely to close by the deadline.
The announcement also confirmed military commissions will go ahead in some cases, so the move to civilian trials is not a general one.
It remains to be seen whether the trial will accept any alleged confession by Khalid Sheikh Mohammed as it might have been based on water-boarding, or whether, in a courtroom close to Ground Zero, he will seek to glory in the attacks.
The five men had until now been facing prosecution at US military commissions in Guantanamo. The government had faced a 16 November deadline to decide how to proceed in their cases.
Mr Holder said he was confident that the defendants would get a fair trial that was "open to the public and open to the world".
Of the five detainees referred for military commission trials, one is Abd al-Rahim al-Nashiri, accused in connection with the 2000 bombing of the USS Cole in Yemen.
Speaking in Tokyo ahead of Mr Holder's announcement, Mr Obama said Khalid Sheikh Mohammed would face "most exacting demands of justice". Mr Mohammed has been described by US investigators as "one of history's most infamous terrorists". They say he has admitted being responsible "from A to Z" for the 9/11 attacks.
Believed to be the number three al-Qaeda leader, he was captured in Pakistan in March 2003. He told a pre-trial hearing at Guantanamo in December 2008 that he wanted to plead guilty to all charges against him.
But intelligence memos released earlier this year revealed he had been subjected to harsh interrogation techniques including water-boarding on multiple occasions since his capture - potentially rendering some evidence inadmissible.
Khalid Sheikh Mohammed was captured in March 2003
The decision to hold the trial in New York faces opposition from some lawmakers and relatives of those who died.
Congressmen Howard McKeon, the senior Republican on the House Armed Services Committee, said the decision would introduce "unnecessary risk to the citizens of New York".
But Democratic Senator Patrick Leahy, who chairs the Judiciary Committee, said the decision demonstrates "to the world that the most powerful nation on earth also trusts its judicial system".
The move is part of a White House bid to close Guantanamo by 22 January 2010.
Mr Obama's administration says it will try some detainees in US courts and repatriate or resettle others who are not perceived as a threat.
However, questions remain over the fate of those assessed as dangerous but who for legal reasons could not be prosecuted in a US court - prompting suggestions that the deadline will slip.
This page is best viewed in an up-to-date web browser with style sheets (CSS) enabled. While you will be able to view the content of this page in your current browser, you will not be able to get the full visual experience. Please consider upgrading your browser software or enabling style sheets (CSS) if you are able to do so.