Sanders said he voted against Lew because he wouldn’t stand up against Wall Street to protect working families.

“Is the new Secretary of Treasury prepared to take on the increasingly powerful oligarchy ... and stand with the working families of this nation who are being beaten up everyday?” Sanders said. “I do not think Jack Lew is that person.”

Lew, who previously served as Obama's chief of staff and budget director, will succeed Tim Geithner, who left the administration earlier this year.

Senate Finance Committee Chairman Max Baucus (D-Mont.) urged his colleagues to support Lew’s nomination and vowed he would work with Congress.

“We need a strong man at the helm to help tackle the many fiscal challenges facing this nation and I believe Jack Lew is that man,” Baucus said. “He is eager to work with all of us here in Congress to strengthen the American economy.”

Lew's nomination was never really in doubt, though questions were raised about his previous work for Citigroup and for compensation he received from New York University. He was approved earlier this week by the Senate Finance Committee in a 19-5 vote.

Sen. Orrin Hatch (R-Utah), that panel's ranking member, voted for Lew on Wednesday and said he believed Obama had the right to choose his cabinet members despite Hatch's reservations about Lew.

"I am bending over backwards to show deference to the president’s nomination and I hope that doesn’t go unnoticed," Hatch said.

Sen. Chuck Grassley (R-Iowa) voted against Lew, and said he was unsatisfied with Lew's answers about his compensation and a Cayman Island account.

“Transparency and sunlight are essential for Congress and the American people because sunshine demands accountability,” Grassley said. “It is important to hold members of this administration to the same standard that they hold against everyone else.”

But Baucus countered that Lew answered more than 700 question from the Finance Committee.

Sen. Jeff Sessions (R-Ala.) said he objected to Lew’s nomination because he thought Lew did a poor job of leading the Office of Management and Budget (OMB) and frequently misrepresented Obama’s budgets.

“My objections come from his running the Office of Management of Budget, which is normally the single office that demands efficiency,” Sessions said ahead of the vote Wednesday. “In that aspect of his job I’ve seen little leadership and at this time of surging debt I would rate that performance as an F. … If the OMB director won’t insist on efficiency and good government, who will?”