Google was accused in a lawsuit of illegally tracking the movements of iPhone and Android users even after they changed settings which they believed would prevent such monitoring, Reuters reported.

Last week it was revealed a number of Google apps and services automatically record a snapshot of user location data, even when users have switched off a setting which plots location history.

Associated Press said the finding was verified by researchers at Princeton University and noted users can be tracked via apps including Google Maps, the company’s weather widget and web searches. Both iOS and Android devices were subject to the issue, the news outlet added.

In documents filed with a federal court in San Francisco, user Napoleon Patacsil stated: “Google represented that a user ‘can turn off Location History at any time. With Location History off, the places you go are no longer stored.’ This simply was not true.”

The court documents add Google principal goal was to “surreptitiously monitor” phone users and allow third parties to do the same. In doing so, the search giant violated privacy laws, including the California Invasion of Privacy Act, the lawsuit claimed.

Patacsil is seeking unspecified damages and class-action status on behalf of US users.

A judge must decide if Patacsil can move forward with these claims and if he can do so on behalf of everyone in the US who may have been affected.