Gen Kiley testified in Congress over the case last week

Gen Kiley becomes the third top-ranking official to lose his job over Walter Reed conditions, which were highlighted last month by the Washington Post.

President Bush has said he is "deeply troubled" after reports of cockroaches and rats in some hospital buildings.

Gen Kiley had filed a "request to retire" on Sunday, the army said.

However, a senior Pentagon official speaking on condition of anonymity said the acting US Army Secretary, Peter Geren, had asked Gen Kiley for his retirement.

The secretary of the army and the head of the medical centre have quit over the reports.

At war

"I submitted my retirement because I think it is in the best interest of the Army," Gen Kiley, who had overseen the army's medical services, said in a statement.

"We are an Army Medical Department at war, supporting an Army at war - it shouldn't be and it isn't about one doctor," the statement said.

The 56-year-old was commander of Washington's Walter Reed Army Medical Center from 2002 to 2004.

Major General Gale Pollock, the Deputy Surgeon General, will replace Gen Kiley until a permanent replacement is found.

"I have confidence she will carry out her responsibilities and lead with skill and distinction," said Peter Geren.

'Huge embarrassment'

Gen Kiley has been accused of playing down the reports by the Washington Post and ignoring earlier warnings about sub-standard care at the hospital.

The scandal over Walter Reed erupted in February

The suspicion will be though that the man who initially played down the reports of cockroaches, mice and mould in the rooms of wounded war veterans, has been pushed, says the BBC's James Coomarasamy in Washington.

This was a scandal which would have been a huge embarrassment at any time, but is particularly bad just as the Bush administration is sending more troops into Iraq, our correspondent says.

The chairman of the House armed services committee said the removal of top Army brass was only a first step towards solving the problems at Walter Reed.

"But this step alone will not fix the problems that our wounded and injured service members experience when they are in recovery," Representative Ike Skelton said in a statement.

"With the installation of new leaders, the real test will be making sure that the work fixing problems actually gets done," he added.