A US army officer has ordered a court martial for Bradley Manning, the soldier charged in the biggest leak of classified information in American history.

Military district of Washington commander Major General Michael Linnington referred all charges against Manning to a general court martial on Friday, the army said in a statement.

The referral means Manning, 24, will stand trial for allegedly giving more than 700,000 secret US documents and a classified combat video to WikiLeaks for publication. He faces 22 counts, including aiding the enemy, and could be imprisoned for life if convicted of that charge.

A judge yet to be appointed will set the trial date.

Defence lawyers say Manning was clearly a troubled young soldier whom the army should never have deployed to Iraq or given access to classified material while he was stationed there from late 2009 to mid-2010.

At a preliminary hearing in December, military prosecutors produced evidence that Manning downloaded and electronically transferred to WikiLeaks nearly half a million sensitive battlefield reports from Iraq and Afghanistan, hundreds of thousands of diplomatic cables, and video of a 2007 army helicopter attack that WikiLeaks dubbed "Collateral Murder".

Manning's lawyers countered that others had access to his workplace's computers. They say he was in emotional turmoil, partly because he was a gay soldier at a time when homosexuals were barred from serving openly in the US armed forces. The defence also claims Manning's apparent disregard for security rules during training in the US and his increasingly violent outbursts after deployment were red flags that should have prevented him from having been given access to classified material. Manning's lawyers also contend that the material WikiLeaks published did little or no harm to national security.

In the December hearing at Fort Meade, Maryland, prosecutors also presented excerpts of online chats found on Manning's personal computer that allegedly document collaboration between him and the founder of WikiLeaks, Julian Assange.

Federal prosecutors in northern Virginia are investigating Assange and others for allegedly facilitating the disclosures.