LOS ANGELES -- People relied on the most popular mobile weather app to track forecasts that determined whether they chose jeans over shorts and packed a parka or umbrella, but its owners used it to track their every step and profit off that information, Los Angeles prosecutors said Friday.

The operator of The Weather Channel mobile app misled users who agreed to share their location information in exchange for personalized forecasts and alerts, and they instead unwittingly surrendered personal privacy when the company sold their data to third parties, City Attorney Michael Feuer said.

Feuer sued the app's operator in Los Angeles County Superior Court to stop the practice. He said 80 per cent of users agreed to allow access to their locations because disclosures on how the app uses geolocation data were buried within a 10,000-word privacy policy and not revealed when they downloaded the app.

"Think how Orwellian it feels to live in a world where a private company is tracking potentially every place you go, every minute of every day," Feuer said. "If you want to sacrifice to that company that information, you sure ought to be doing it with clear advanced notice of what's at stake."

A spokesman for IBM Corp., which owns the app, said it has always been clear about the use of location data collected from users and will vigorously defend its "fully appropriate" disclosures.

Feuer said the app's operators, TWC Product and Technology LLC, sold data to at least a dozen websites for targeted ads and to hedge funds that used the information to analyze consumer behaviour.

The lawsuit seeks to stop the company from the practice it calls "unfair and fraudulent" and seeks penalties of up to $2,500 for each violation. Any court decision would only apply to California.

Marketed as the "world's most downloaded weather app," The Weather Channel app claims approximately 45 million users a month, the lawsuit said.

Users who download the free app are asked whether to allow access to their location to "get personalized local weather data, alerts and forecasts." It does not say how the company benefits from the information.

While disclosures may be included in the privacy policy, state law says "fine print alone can't make good what otherwise has been made obscure," Feuer said.

He said he learned about the sale of the private data from an article in The New York Times.

The lawsuit comes as companies, most notably Facebook and Google, are increasingly under fire for how they use people's personal data. Both companies faced congressional hearings last year on privacy issues, which are likely to remain on lawmakers and regulators' minds both nationally and in California.

In June, California lawmakers approved what experts are calling the country's most far-reaching law to give people more control over their personal data online. That law doesn't take effect until next year.

Feuer said he hopes the case inspires other lawsuits and legislation to curb data-sharing practices.

IBM bought the app along with the digital assets of The Weather Company in 2015 for $2 billion but did not acquire The Weather Channel seen on TV, which is owned by another company.

AP Technology Writer Barbara Ortutay contributed to this report.