WASHINGTON — In a landmark vote for gay rights, the Senate set the stage for passage Saturday of legislation that would overturn the military ban on openly gay troops, and President Barack Obama said it was "time to close this chapter in our history"

Repeal would mean that, for the first time in American history, gays would be openly accepted by the military and could acknowledge their sexual orientation without fear of being kicked out. More than 13,500 service members have been dismissed under the 1993 law known as "don't ask, don't tell."

A 63-33 test vote — 60 votes were need to advance the measure — earlier Saturday paved the way for passage, and Senate Majority Leader Harry Reid, D-Nev., said a final vote would come at 3 p.m. The House had passed an identical version of the bill, 250-174, earlier this week, so Senate approval would send the measure to the White House.

Even after the measure were to become law, the policy change wouldn't go into effect right away. Obama and his military advisers would have certify that the change wouldn't hurt the ability of troops to fight, and there would also be a 60-day waiting period. Some have predicted the process could take as long as a year before Bill Clinton-era policy is repealed.

With an end to the ban, "no longer will our nation be denied the service of thousands of patriotic Americans forced to leave the military, despite years of exemplary performance, because they happen to be gay," Obama said in a statement. "And no longer will many thousands more be asked to live a lie in order to serve the country they love."

Rounding up a filibuster-proof majority in the Senate was a historic victory for Obama, who made repeal of the policy a campaign promise in 2008. It also was a political triumph for congressional Democrats who struggled in the final hours of the postelection session to overcome GOP objections on several legislative priorities before Republicans regain control of the House in January.

"As Barry Goldwater said, 'You don't have to be straight to shoot straight,'" said Reid, D-Nev., referring to the late GOP senator from Arizona.

Sen. John McCain, Obama's GOP rival in 2008, led the opposition. Speaking on the Senate floor minutes before the test vote, the Arizona Republican acknowledged he didn't have the votes to stop the bill. He blamed elite liberals with no military experience for pushing their social agenda on troops during wartime.

"They will do what is asked of them," McCain said of service members. "But don't think there won't be a great cost."

In the end, six GOP senators broke with their party in favor of repeal. Republicans supporting the bill were Sens. Susan Collins of Maine, Olympia Snowe of Maine, Scott Brown of Massachusetts, Lisa Murkowski of Alaska, George Voinovich of Ohio, and Mark Kirk of Illinois.

West Virginia Democratic Sen. Joe Manchin, the only Democrat to oppose repeal, did not vote.

The GOP lawmakers swung behind repeal after a recent Pentagon study concluded the ban could be lifted without hurting the ability of troops to fight.

Obama said the policy "undermines our national security while violating the very ideals that our brave men and women in uniform risk their lives to defend." He also said "we can responsibly transition to a new policy while ensuring our military strength and readiness."

"It is time to close this chapter in our history. It is time to recognize that sacrifice, valor and integrity are no more defined by sexual orientation than they are by race or gender, religion or creed," he added.

Advocacy groups who lobbied hard for repeal hailed the vote as a significant step forward in gay rights. The Servicemembers Legal Defense Network called the issue the "defining civil rights initiative of this decade."

Supporters of repeal filled the visitor seats overlooking the Senate floor, ready to protest had the bill failed.

"This has been a long fought battle, but this failed and discriminatory law will now be history," said Joe Solmonese, president of the Human Rights Campaign.

The Pentagon study found that two-thirds of service members didn't think changing the law would have much of an effect. But of those who did predict negative consequences, a majority were assigned to combat arms units. Nearly 60 percent of the Marine Corps and Army combat units, such as infantry and special operations, said in the survey they thought repealing the law would hurt their units' ability to fight.

The Pentagon's uniformed chiefs are divided on whether this resistance might pose serious problems.

Marine Corps Commandant Gen. James Amos has said he thinks lifting the ban during wartime could cost lives.

"I don't want to lose any Marines to the distraction," he told reporters this week. "I don't want to have any Marines that I'm visiting at Bethesda (Naval Medical Center) with no legs be the result of any type of distraction."

Adm. Mike Mullen and Marine Gen. James Cartwright, the chairman and vice chairman of the Joint Chiefs of Staff, respectively, have said the fear of disruption is overblown. They note the Pentagon's finding that 92 percent of troops who believe they have served with a gay person saw no effect on their units' morale or effectiveness. Among Marines in combat roles who said they have served alongside a gay person, 84 percent said there was no impact.

Online:

Pentagon study: http://tinyurl.com/23lxc49

Servicemembers Legal Defense Network: http://www.sldn.org/