The 56-43 vote fell four shy of the 60 votes needed to cut off debate on the bill, co-sponsored by Sens. Patrick Leahy, D-Vt., and Arlen Specter, R-Pa. It was a blow for human rights groups that say a current ban on habeas corpus petitions could lead to the indefinite detention of individuals wrongfully suspected of terrorism.
President Bush and conservative Republicans counter that the ban, enacted last year, was necessary to stem the tide of legal protests flooding civilian courts.
Among the 56 senators voting in favor of expanding detainees' rights were six Republicans: Specter, Olympia Snowe of Maine, Chuck Hagel of Nebraska, Richard Lugar of Indiana, John Sununu of New Hampshire and Gordon Smith of Oregon.
Leahy said he would try again to repeal it, although he was not sure when he would get another chance.
"The truth is that casting aside the time-honored protection of habeas corpus makes us more vulnerable as a nation because it leads us away from our core American values," Leahy said. "It calls into question our historic roll as a defender of human rights around the world."
In 2006, Congress passed and Mr. Bush signed into law the Military Commissions Act, which established a military-run tribunal system for prosecuting enemy combatants. The provision barring habeas corpus petitions means that only detainees selected for trial are able to confront charges against them, leaving most military detainees in custody without a chance to plead their case.
Sen. Lindsey Graham, R-S.C., one of the architects of the law, said the system includes checks and balances to determine whether a person is being held unlawfully. Granting a ban on habeas corpus petitions would allow terrorism suspects to go "judge shopping" around U.S. courts to find a sympathetic ear, he said.
Added Sen. Jon Kyl, R-Ariz.: "Never has such an unprecedented legal right been granted to a prisoner of war or detainee."
In June, the Supreme Court agreed to consider whether the ban on habeas corpus petitions is constitutional, although no argument date has been set.
Specter, the lone Republican to co-sponsor the bill, has said he anticipates the court will rule the ban unconstitutional.
Habeas corpus "is a constitutional right that has existed since the Magna Carta in 1215," he said.