Washington (CNN) — Two leading US lawmakers have reached a bipartisan deal that could, for the first time, grant all Americans a basic right to digital privacy and create a national law regulating how companies can collect, share and use Americans’ online data.

If it succeeds, the proposal could establish the US equivalent of the European Union’s landmark privacy law known as the General Data Protection Regulation (GDPR), and rein in what privacy advocates say is a lawless and unregulated space where Americans’ personal data can too easily be shared and sold to the highest bidder.

The proposed agreement would create an unprecedented, single federal standard governing digital privacy in the United States and reflects a significant breakthrough after years of stalled negotiations between Republicans and Democrats. But it could also override some of the toughest state-based privacy laws in the nation, such as in California.

The deal comes as personal data has increasingly become the lifeblood of the modern economy and as artificial intelligence companies have raced to hoover up as much of it as they can to train sophisticated AI models that could transform society.

On Sunday, the lawmakers involved — Washington Sen. Maria Cantwell, the Democratic chair of the Senate Commerce Committee, and Washington Rep. Cathy McMorris Rodgers, the Republican who leads the House Energy and Commerce Committee — announced a proposal they said would return control of personal data to American consumers.

The discussion draft, which was released over the weekend but has not yet been formally introduced as legislation, covers data brokers, tech platforms, telecom providers and virtually every other type of organization an internet user might interact with on a daily basis, with the exception of small businesses and government contractors.

The lawmakers’ proposed American Privacy Rights Act would ban the transfer of Americans’ sensitive personal data to third parties — including geolocation histories, financial data, biometric information and calendar and phone logs — unless a user provides explicit approval for the data or the sharing is for one of several specific purposes allowed under the bill, such as preventing fraud.

It would let users opt out of targeted advertising altogether and require companies to collect only enough data as they need to do their business. And it would guarantee Americans the right to request copies of their data, to correct it or even to have it deleted from a company’s records.

And, in a nod to growing concerns about whether Americans’ personal data may be available to foreign adversaries such as China and Russia, the legislation would require companies to disclose to US consumers whether their information may be sent to, stored or processed in one of those countries. US officials have voiced concerns about whether TikTok user data could be accessed by the Chinese government, but it doesn’t stop there: The Biden administration and US lawmakers have also highlighted data brokers as another potential way for foreign governments to obtain Americans’ personal data.

The draft legislation breaks a yearslong deadlock between Republicans and Democrats over the scope of any national privacy bill. The two parties had long disagreed over two key issues: Whether a federal privacy law should override existing state privacy laws that may provide tougher protections, and whether private citizens should be able to bring their own lawsuits against companies accused of violating their privacy.

This week’s agreement appears to resolve both issues. It would preempt more than a dozen state privacy laws already on the books in states such as California, Texas and Virginia. And it would enable individuals to sue companies for violations of the proposed law.

“This bipartisan, bicameral draft legislation is the best opportunity we’ve had in decades to establish a national data privacy and security standard that gives people the right to control their personal information,” said McMorris Rodgers and Cantwell in a statement.

The legislation has a long road ahead: It must still clear both of the lawmakers’ committees and pass both chambers of Congress in order to make it to President Joe Biden’s desk. Policy experts have predicted low odds of Congress passing much legislation in the months leading up to the 2024 election.

McMorris Rodgers has also announced she will not run for reelection, which could complicate the bill’s future after one of its most powerful co-sponsors leaves the House.

The-CNN-Wire™ & © 2024 Cable News Network, Inc., a Time Warner Company. All rights reserved.

Join our Newsletter for the latest news right to your inbox