President Barack Obama announced Friday that he will sign a bill that would make the unlocking of cellphones legal.

The move is being made after the bill was passed by the House just hours earlier and approved by the Senate last week, according to Politico. The passing of the bill reverses a decision made by the Library of Congress that made unlocking mobile devices to use them on other networks illegal.

"The bill Congress passed today is another step toward giving ordinary Americans more flexibility and choice so that they can find a cellphone carrier that meets their needs and their budget," Obama said.

The bill is called the "Unlocking Consumer Choice and Wireless Competition Act." While carriers have always been able to unlock their phones on their own, convoluted rules would dictate if and when they could be unlocked. Now, phone users can unlock the mobile devices they receive through a carrier, The Verge reported.

"I commend Chairman Leahy and Goodlatte, and Ranking Members Grassley and Conyers for their leadership on this important consumer issue and look forward to signing this bill into law," Obama said.

The Obama Administration announced its support in passing the bill after the White House website received a petition with 114,000 signatures in favor of making cellphone unlocking legal last year, Politico reported.

Public Knowledge Staff Attorney Laura Moy said the bill will "make it easier for consumers to switch from one provider to another, improving competition in the wireless market. It will improve the availability of free and low-cost secondhand phones for consumers who cannot afford to purchase new devices, and it will keep millions of devices out of landfills."

The White House did not give word on when the bill will be signed.

Despite the victory for the bill's supporters, the new legislation is not permanent, The Verge reported. The Library of Congress will reconsider the rule again in 2015 and every three years afterwards, unless changes are made.

"The cellphone unlocking bill has a direct impact on Americans as we become more reliant on our wireless devices," said Senator Chuck Grassley (R-IA). "This bipartisan bill is pro-consumer and pro-competition and allows for greater ease in the portability of devices. It will provide greater competition and more consumer choice."