The Senate Judiciary Committee voted unanimously Thursday to advance legislation that would legalize cell-phone unlocking, which would make it easier for consumers to switch providers without buying a new phone.

The House passed similar legislation earlier this year.

"Consumers should be able to use their existing cell phones when they move their service to a new wireless provider," said Sen. Patrick Leahy, the committee chairman and sponsor of the legislation.

"With today's strong bipartisan vote in the Judiciary Committee, I hope the full Senate can soon take up this important legislation that supports consumer rights."

Most contract cell phones come "locked" to one carrier. Because of a decision by the U.S. Copyright Office in 2012, customers must obtain their carrier's permission to legally unlock their phones to switch to a competitor—even after they have completed their contract.

The decision prompted an immediate public backlash, and more than 114,000 people signed a White House petition in protest.

The Unlocking Consumer Choice and Wireless Competition Act, which is cosponsored by the committee's top Republican, Chuck Grassley, would overturn the office's decision. The bill would also direct the office to consider whether to allow unlocking of other devices, such as tablets.

Consumer groups such as Public Knowledge and the Electronic Frontier Foundation support the bill, although they have also pushed for broader legislation that would amend the underlying copyright law.

Unlike the House bill, the Senate legislation leaves out controversial language to prohibit people from unlocking phones in large batches. The cellular carriers had lobbied for the House language, arguing it was important to thwart "large-scale" theft operations. But the language caused many lawmakers and advocacy groups to pull their support, saying it would create unnecessary barriers to switching carriers.

CTIA, the lobbying group for cell-phone carriers such as Verizon and AT&T, supports the legislation in both chambers.

Under pressure from the Federal Communications Commission, all the major carriers already signed on to a commitment last year to allow their customers to unlock their phones.