Updated at 3:12 p.m. ET

The Senate passed a bill raising the debt ceiling that is aimed at averting a government default, clearing the way for President Obama to sign it into law.

The final vote was 74-26. Nineteen Republicans, six Democrats and independent Bernie Sanders of Vermont opposed the measure, which cuts $2.1 trillion in federal spending while increasing the amount the government can borrow to pay its bills.

Obama spoke at the White House before he signed the bill. USA TODAY's David Jackson has more in The Oval.

Senate Majority Leader Harry Reid, D-Nev., hailed the bill as the result of stressful negotiations in which no one got everything they wanted. "The product we have here is one of compromise," he said.

Senate Minority Leader Mitch McConnell, R-Ky., who helped broker the accord this weekend, said Republicans have succeeded in changing the debate in Washington.

"The spending spree might actually be coming to an end," he said. "This bill does not solve the problem, but it at least forces Washington to admit that it has one."

The House passed the bill last night on a 269-161 vote. The "yes" votes came from an eclectic, bipartisan mix consisting of 174 Republicans -- two-thirds of Speaker John Boehner's majority caucus -- and 95 Democrats.

Some Democrats balked at the agreement reached by Obama and congressional leaders because it contained no provisions for new taxes to generate revenue and cuts deeply into education and other programs that help the middle class.

"A sugar-coated Satan sandwich" is what Congressional Black Caucus Chairman Emanuel Cleaver, D-Mo., called the deal.

The Senate action caps months of bitter, partisan wrangling over government spending that had been set in motion last November with the election of scores of Republicans backed by the fervent Tea Party movement.

The Tea Party's mantra of small government and no new taxes helped usher a GOP majority into the U.S. House and enough Republicans to narrow the reach of Democrats in the Senate -- thereby changing the debate in Washington about the nation's fiscal policy.

"Finally, Washington is taking some responsibility for spending money we don't have," said Sen. Lamar Alexander, R-Tenn. "This is a change in behavior -- from spend, spend, spend to cut, cut, cut."

Still, for a handful of Tea Party-backed senators, the deal does not go far enough to rein in federal spending and reduce the nation's debt. Sens. Rand Paul of Kentucky, David Vitter of Louisiana, Marco Rubio of Florida and Mike Lee of Utah all voted "no" today.

"The current deal to raise the debt ceiling doesn't stop us from going over the fiscal cliff," Paul said. "At best, it slows us from going over it at 80 mph to going over it at 60 mph."