Facebook was for years a best friend to the data brokers who make hundreds of millions of dollars a year gathering and selling Americans' personal information. Now, the world's largest social network is souring that relationship — a sign that the company believes it has overshadowed their data-gathering machine. 

Facebook said late Wednesday that it would stop data brokers from helping advertisers target people with ads, severing one of the key methods marketers used to link users' Facebook data about their friends and lifestyle with their offline data about their families, finances and health.

The data brokers have for years served a silent but critical role in directing users' attention to Facebook's ads. They also, critics say, stealthily contributed to the seemingly all-knowing creepiness of users seeing ads for things they never mentioned on their Facebook pages. A marketer who wanted to target new mothers, for instance, could use the data brokers' information to send Facebook ads to all women who bought baby formula with a store rewards card.

Acxiom, Experian and other data brokers once had a prized seat at Facebook's table, through a program called Partner Categories, that allowed advertisers to tap into the shadow profiles crafted with data from Facebook and the brokers to drill down on their target audience. The data brokers got a cut of the money when the ads they helped place turned into a sale, and Facebook also shared some data with the brokers to help gauge how well its ads performed.

A Facebook director said in a statement that the company will wind down that program over the next six months, which “will help improve people’s privacy on Facebook.” But privacy experts saw the move as an assertion of dominance from the social network, which in recent years has consolidated its power over an increasingly intimate level of detail about its users' lives — and wants advertisers to pay for its expertise.

“Facebook is officially in the data-mining business,” said Joel Winston, a privacy lawyer in Pittsburgh. “It's a definitive signal that Facebook's data capture and identity-targeting technology is light-years ahead of its competitors'.”

[Facebook makes its privacy controls simpler as company faces data reckoning]

The move comes as Facebook battles a major privacy scandal in the wake of revelations that a political data firm, Cambridge Analytica, took advantage of the site's loose privacy rules and improperly obtained data on more than 30 million Facebook users. The company has in recent days outlined steps showing how users can see and limit what Facebook knows about them, following what chief executive Mark Zuckerberg called a “major breach of trust.”

In 2015, Facebook restricted the kinds of data that outside developers, including the researcher who fed data to Cambridge Analytica, could gather from users and their friends. Christopher Wylie, Cambridge Analytica's whistleblower, told The Washington Post that Cambridge Analytica had paired Facebook data with information from data brokers to build out its voter profiles.

But the social network continued to strengthen its ties with the data brokers who gather and repackage user information. That year, Acxiom said its involvement in Partner Categories helped its advertising clients use Facebook “to better connect with people more inclined to buy certain products or services,” adding that its clients included most of the country's top 10 insurers, retailers, automakers, hotels, telecommunications giants and banks. One year earlier, in 2014, the Federal Trade Commission issued a report finding that data brokers had collected information on nearly every American and saying that the brokers “operate with a fundamental lack of transparency.”

While Facebook gathers much of its 2 billion users' online information, the data brokers attempt to scoop up everything else, including billions of bits of information from voter rolls, property records, purchase histories, loyalty card programs, consumer surveys, car dealership records and other databases.

[Facebook’s discussions with Congress signal Mark Zuckerberg will testify amid data-privacy scandal]

The brokers use that raw data to build models predicting (with varying success) many hundreds of details about a customer's behavior, finances and personality: age, family status, household income, whether she likes crossword puzzles, interest in buying a household pet, likelihood of having a funeral plan. The data brokers then sell those consumer profiles to marketers and major conglomerates seeking a vast and targeted customer base — including on Facebook, which now accounts for a fifth of the world's online ads.

Acxiom, the Arkansas-based broker that has worked with Facebook since 2013 and reported more than $880 million in revenue last year, estimated Facebook's ditching of its data-sharing program would carve as much as $25 million from the company's revenue and profit. In a statement late Wednesday, Acxiom said Facebook had alerted it that day to the news. “Today, more than ever, it is important for businesses to be able to rely upon companies that understand the critical importance of ethically sourced data and strong data governance. These are among Acxiom’s core strengths,” chief executive Scott Howe said. Its stock plunged more than 30 percent Thursday morning.

Representatives for data broker Experian did not respond to questions, and data broker Oracle Data Cloud declined to comment. Experian stock moved downward slightly, while Oracle shares traded up about 1 percent. Facebook shares climbed about 3 percent, helping puncture weeks of losses.

Data brokers' models are often intricately and oddly detailed: Acxiom has categorized people into one of 70 “household life stage clusters,” including “Career-Centered Singles,” “Soccer and SUVs,” “Apple Pie Families” and “Rolling Stones.” But advertisers wanting more information — served straight from the source, in the person's own words — have increasingly turned to Facebook, where they can grab first-party data from the actual customer, and not just third-party data gathered and analyzed from afar.

Facebook and the data brokers have often dealt in the same kinds of personal information advertisers find impossible to resist. Experian, for instance, runs a Newborn Network that sells advertisers detailed information, gleaned from personal spending and demographic data, of women they predict are new and expectant mothers; the company says it “captures more than 80 percent of all U.S. births.” But Facebook users also freely share baby photos and mark their life events — a more direct way of relaying the same information to sellers of baby formula, cribs and maternity clothes.

Advertisers will still be able to work with the data brokers to gather information and target customers; they'll just have to do it outside Facebook. Critics pointed to a few ways, such as Facebook's Custom Audiences tool, that will allow advertisers to still target customers en masse based on financial and other data they've pulled from across the Web.

Some privacy experts cheered Facebook's data-broker move as a step toward preserving user privacy. “It’s long overdue that Facebook owned up to the serious erosion of consumer privacy made possible by its alliance with powerful data brokers,” said Jeffrey Chester, executive director of the Washington privacy-rights nonprofit Center for Digital Democracy.

[Why Facebook users’ data obtained by Cambridge Analytica has probably spun far out of reach]

Chris Sperandio, a product head of privacy at the marketing-data start-up Segment, said the move also helps Facebook dodge growing questions over the source of its user information. That is quickly becoming a high-stakes legal issue: A sweeping privacy rule coming to Europe in May, the General Data Protection Regulation, will make the company more liable and accountable for knowing where its data comes from.

“Third-party data is supplied by a vendor, and this data that the vendors supply is often gathered through questionable means,” Sperandio said. “Having a third-party vendor only muddies the waters, especially when it’s not as clear to the user how the third-party vendor got the data.”

But some critics questioned what effect the move would have in a site that counts selling access to its users' information as its biggest moneymaker. Facebook, privacy experts said, nets a vast range of real-time information — friendships, photos, work histories, interests and consumer tastes, as well as mobile, location and facial-recognition data — that advertisers view as more current and accurate than the broker information inferred from old receipts and government logs. What, they ask, would advertisers need to pay data brokers for?

“We don't know enough about Facebook's data trove to know whether their abandonment of Partner Categories helps users avoid privacy invasions,” said Frank Pasquale, a University of Maryland professor who specializes in algorithms and privacy. “Even if we did have that knowledge, we have little reason to trust Facebook to actually follow through on it. It may well change course once media attention has gone elsewhere.”

Elizabeth Dwoskin contributed to this report.