Those who did not install the app or deleted after installation would be detained for up to 10 days.

Jinwang also keeps a copy of Weibo and WeChat records, as well as a record of IMEI numbers, SIM card data and Wifi login data. The records are then sent to a server.

“While the authorities have the responsibility to protect public safety, including by fighting terrorism, such mass collection of data from ordinary people is a form of mass surveillance, and an intrusion to privacy,” she said.

“I think there is reason to be concerned about what kinds of data these apps may be collecting about users and their activity without their knowledge or consent,” said Joshua Rosenzweig, a Hong Kong-based analyst with Amnesty International.

Xinjiang has a population of eight million Uighurs, a Turkic ethnic group. Its people have complained of longstanding oppression under the country’s Communist government.

In March, the country banned veils and the growing of long beards — traditional Muslim customs.

Last year, Xinjiang residents who used foreign messaging apps such as Whatsapp found they had their phone services cut.