Health QR Code: Technological and/or Social Infrastructure about Pandemic Control and Privacy

Health QR Code: Technological and/or Social Infrastructure about Pandemic Control and Privacy

How can we balance the benefits and risks of such big-scale surveillance systems? This is a tricky problem.

Written by Jack Linzhou Xing
Published on 03/02/2021

Over the year 2020, the Covid-19 pandemic has swept all over the world. While the outbreak firstly took place in mainland China, it was firstly effectively controlled in mainland China. Since the late spring of 2020, China seemed to have entirely got rid of the pandemic, until the winter when small-scale outbreaks made a comeback. 

Why was that? While different people have different answers from various aspects, many would attribute it to the application of a technology – the health QR code. Different from usual cases in which people typically take a technological deterministic view that the creation of technology per se can make a difference, this time, people seem to fully understand that the technology can only be effective when the whole society coordinates with, or is forced to coordinate with it. This is shown by the fact that although multiple countries and regions, including Singapore, Hong Kong, Korea, Taiwan, Iran, and Israel (notably, most are East Asian countries) also adopt similar systems,[1] not every system succeeds.

Create an App or Build into an Existing System: A Big Difference

The health QR code system is used to trace people’s movement between different places within a city or a country. In the case of mainland China, the system is installed as a function in the apps of Alipay or WeChat, for which the user needs to register by using a phone number. Users’ track of movements is noted and recorded within the system through GPS. When the user goes to a public, business, or service site, or go to different countries, he or she is required to scan his or her QR code to record his or her track. When the track shows that a user has been to a place where someone tested positive have been to within a range of time, the QR code will change its color (usually from green to yellow or red). Under this situation, he or she will be denied access to certain public, business, or service sites such as schools and stadiums. When there are outbreaks, the system is also used as a way to trace close contacts.

To some people’s surprise, the health QR code system in China was not invented or designed initially by its big tech firms such as Alibaba or Tencent. Instead, it was invented within a very limited time by an IT team organized by the Public Security Bureau of Hangzhou City. In February 2020, when the pandemic was reaching its peak in China but people were moving back to big cities from their hometown after the Chinese New Year, various city governments started to have a headache about the potential risks that incoming population flow could bring to the pandemic control. Under this situation, the Public Security Bureau (police bureau) of Hangzhou City organized a temporary team led by Zhong Yi (钟毅), staff at the cybersecurity section, to develop an IT-based tool to help trace people’s movements, where users’ smartphones can be used as a clue to determine their locations and close contacts at any time. After three days of hard work, Zhong’s team finished the task.[2]

Fig. 1  The health QR code used in Hangzhou. 

The fact that Hangzhou was the first city to invent an IT-based health tracing system in China is not surprising. As the birthplace of the Chinese tech giant Alibaba, Hangzhou has always been a pioneer in adopting digital-based everyday service and surveillance technologies which include ride-sharing, sharing bikes, QR-code-based subway entrances, e-payment systems, etc. Its police bureau, correspondingly, is experienced in adopting IT tools to deal with public-security- and surveillance-related cases.

Of course, inventing a system is not the end. How should the government adopt it and let it spread among citizens? Should the tracing system be installed as an independent software or app? In Hong Kong and Singapore where the government also adopted similar tracing systems, the government decided to create a new app. But in Hangzhou and China, the government decided to utilize existing apps that almost every citizen uses: Alipay and WeChat. Such a choice proved wise. Within the first day of the launching of the health QR system in Hangzhou and even before the government imposed any regulations, more than 1.3 million citizens had already registered for it.

To be sure, this choice requires some preconditions. First, the existing system should be widespread and popular, and Alipay and WeChat obviously fulfilled this standard. As of 2020, Alipay has already got 0.9 billion active users in China,[3] while WeChat has already got 1.1 billion active users as early as in 2019.[4]

Second, the design of the existing system should allow sub-systems or tools developed by other developers to be used within its app. Again, both Alipay and WeChat contained this function. In the case of Alipay, it has long been allowing and providing sub-services within its app, ranging from phone bill payments, online financing tools, and ride-sharing services. In the case of WeChat, according to Tencent’s own investment relation report, it has long been containing the function of “mini-programs” (xiao chengxu, 小程序) to provide native app-like experiences without leaving the Weixin [WeChat] interfaces, [whose advantage including] enhancing user experience for low frequency interactions, freeing up memory space on smartphones, and enabling convenient social sharing.[5] With these existing functional designs within Alipay and WeChat, the health QR code system can easily be incorporated into the functions of these two apps without any effort in customization. This allows the system to appear in every citizen’s screen within several days after the system was developed.

For the third and the arguably most important precondition, Chinese tech firms are used to cooperating with or even acting under the order of the central and local governments in China, and correspondingly, they have routinized and highly efficient mechanisms to collaborate with urgent government requests. Outside the political structure and environment that are similar to those of China, it is not easy to imagine that private enterprises can collaborate with the government in such a smooth manner. Some may argue that building the health QR code system within existing popular apps is not significant to its spread – anyway, the Chinese government would order that every citizen should obtain a QR code on their smartphone. Such a view overlooks the fact that the health QR code system was massively and mandatorily implemented as late as March or April 2020, well before the government-organized development teams needed to improve the system to make it as convenient and accurate as possible, and to persuade public, business, and service sites to adopt it. The widespread usage of Alipay and WeChat contributed significantly to the mass registration and usage even before any government regulations, allowed the development team to test and improve the system according to user experiences before the regulation, and lowered the time and administrative cost for the government to promote or order the usage of the system.

Social and Political Institutions for the Health QR Code

No matter how widespread the health QR code is, it is hard for it to reach its ultimate purpose – to control the pandemic. It is the various social and political institutions that coordinate with the health QR code system that achieve this goal.

The most important and obvious social and political condition lies in the fact that regulations of the government can be effectively obeyed by operators of public, business, and service sites, as well as any individual. Given the government’s central role in people’s everyday social life and its wide-ranged scope of administrative power, regulations by local governments are effectively enforced in every corner of the society.

Of course, such a capacity of local governments is not always available: local government officials, especially grassroots officials, were ordered by their superiors to put pandemic control as the highest priority. This “highest priority” indicates that the results and achievements related to pandemic control are directly linked to the promotion and demotion of the officials. Given that Chinese officials are not directly elected by citizens but promoted or demoted by their superior government or party agencies, punishment on “ineffective” officials can be easily and quickly made from above. Ever since early 2020, the list of the officials who were demoted because of pandemic control includes the directors and party secretaries of Hygiene and Health

Commissions of Hubei Province, Wuhan City, Qingdao City, Shijiazhuang City, Huanggang City, Harbin City, Tonghua City, Hohhot City, and Jilin City, etc., followed by a much longer list of officials of lower ranks. Under this situation, it is not surprising that officials of all ranks tried their best to enforce all kinds of pandemic control regulations in every corner of the geographical unit they are in charge of.

This social and political institution is not obtained by every country or region which adopts similar tracing code systems. While Singapore, with an efficient, comprehensive, and authoritarian governmental structure, achieved a high coverage rate and effectiveness of their app “TraceTogether”,[6] places like Hong Kong failed to do so. On the one hand, the political tradition of laissez-faire governance, the respect to legal and political procedure, and the corresponding limited government capacity in Hong Kong got in the way of the government in implementing thorough and forceful measures. On the other hand, the unique bureaucratic personnel institutions for government officials and political leaders, who are subject to neither direct democratic election or impeachment nor quick promotion or demotion from the superior, significantly hurt the incentive for government officials to implement such measures.

As a compromise, the Hong Kong Government launched an independent app named “LeaveHomeSafe,” which can be freely and voluntarily downloaded by citizens. When entering and leaving the existing public, business, and service sites, citizens can scan the QR codes on the walls of such sites via the app to record their track, and when someone dropping by certain sites is tested positive, other citizens dropping by the same site at the same time and who recorded their track can receive notifications.[7] Somewhat ironically, app registration is voluntary on both sides of citizens and the sites. Moreover, the notification is only for citizens, while there is no evidence showing that the government uses the data in the app to conduct epidemiological investigations. The effectiveness of such a system, without any doubt, is limited.

“Domesticating” Hotpot: The Hidden Development of Convenience

Despite the downplay of the convenience feature in the period from the late 1980s to early 2000s, hotpot chains never stopped exploiting this feature. Chongqing-style hotpot is a pioneer in this direction. Given that the condiments (including chili peppers, Sichuan peppers, garlic, salts, etc.) of Chongqing-style hotpot are precooked in beef tallow, restaurants made instant bags of hotpot seasoning (huoguo diliao, 火锅底料) in the shape of bricks made of solidified beef tallow. Slightly differently, the famous hotpot chain Little Sheep (小肥羊) made hotpot seasoning into powder, while Haidilao made their product as a sauce.

All these inventions, starting to be popular in the mid-2000s, fully exploited the convenience of the already convenient cuisines of hotpot – now people can simply buy hotpot seasoning, boil them in waters with a pot, add meat, vegetable, and other raw ingredients bought from the market, and enjoy hotpot at home.

Fig. 2  The “LeaveHomeSafe” app launched in Hong Kong. 

Another important social and political institution that supports the effectiveness of the health QR code lies in Chinese local governments’ ability to effectively track or quarantine virtually any potential patients and/or close contacts, or even anyone who is suspected to have the risk of being infected by the virus – by this I mean people coming from areas with a higher reported number of infections.

With the help of the health QR code and the internal reporting system of the government disease control agencies, the Chinese government subdivided different places according to the locations of villages or street office, and categorized them as of high risk, medium risk, or low risk according to reported numbers of infections. Moreover, it also categorized different countries as having various levels of risk. Based upon this categorization, each province, city, and even county has its own regulations on quarantine procedures. Take recent Shaanxi Province as the example, any domestic incoming passenger who comes from places with medium and high risks, regardless of the location of his or her household registration (hukou, 户口), is subject to 14 days of centralized quarantine at the hotels arranged by the government, plus 14 days of home quarantine afterward. For passengers coming (back) from other countries, they are subject to 21 days of centralized quarantine at the hotels arranged by the government, plus 14 days of home quarantine afterward. Moreover, the government of high- and medium-risk places routinely conduct lockdown to control population flow.

To be sure, the easiness of conducting mobility control largely goes hand in hand with citizens’ submissive and collaborative behaviors given the government’s central role in people’s everyday social life and its wide-ranged scope of administrative power.

The easiness of mobility control, together with its preconditions, is a key social and political institution to guarantee the effectiveness of a digital tracing system, because it ensures that any “suspicious source of infection” can be physically kept from contacting other people. In this sense, it is more appropriate to argue that the health QR code system is a component of the whole social, administrative, and political system of pandemic control.

Shortcomings and Potential Risks: Fragmentation and Privacy

The effectiveness of China’s health QR code system does not mean that it has no shortcomings and risks. I would argue that such shortcomings and risks, and their advantages, are in a sense two faces of the same coin.

The first major shortcoming of this large system is its fragmentation of operation across different cities and provinces. Following Hangzhou, different cities and provinces developed the health QR code systems, yet each city or province has its own system, which is not necessarily connected to the others. In the best cases, one or two provinces may share or connect their health QR code systems. But in worst cases, the systems of nearby cities are disconnected. To raise a quick example, the systems of Guangzhou and Shenzhen, two major cities next to each other, were connected only after July 2020, four months after they each adopted their own systems. Considering the huge daily population flow between Guangzhou and Shenzhen, such a move was fairly slow. As late as December 2020, multiple departments under the central government, led by the National Hygiene and Health Commission, released an administrative notification to push the integration of health QR code systems.[8]

Such fragmentation is just a manifestation of the overall regional fragmentation of pandemic control policies. Different cities and different provinces have very different regulations regarding the treatment of people from different categories of regions, the length and arrangement of quarantine, the times of virus tests, and the restrictions for people to go to public spaces and use public transportations. All these aspects of fragmentation caused major difficulties for people to move and live their everyday life.

To be sure, some may argue that the fragmentation is caused by the difficulty of unified administration given China’s wide geographical area and huge regional social disparity. Moreover, I would also argue that such fragmentation has the same origin as officials’ high incentives to enforce strict pandemic control regulations. Under the situation of huge regional social disparity, local governments are on the one hand given a large authority to freely test and conduct different kinds of pandemic control policies, and on the other hand subject to investigations, promotions, and demotions that are directly linked to the result of their policies. The fragmentation of health QR code systems and the pandemic control policies as a whole shows the fact that government officials in different provinces and cities have the agency to implement strict regulations and compete with officials in other provinces and cities. In my opinion, this can be seen as an institutional arrangement of region tournament competition in terms of pandemic control, just as the tournament competition happening in the realm of economic development in China, as economists famously argued.[9]

Another major shortcoming or concern, which is arguably the most evident and dangerous, is about personal data privacy and discrimination. The health QR code system has opened an opportunity for the government and all government-related entities to freely get all the citizens’ track and travel history as well as the corresponding health conditions. Such information is significant for the government to conduct rigid, comprehensive, and hyper-accurate surveillance of each individual, and has great potential profitability in the commercial sense. Therefore, regardless of the governmental sense and the commercial sense, mass encroachment of personal data privacy is made more possible than any time ever by the health QR code system. The problem of discrimination is in a sense related to the concern about privacy. In the first sense, discrimination means to discriminate against people coming from places with a pandemic. Will the right of governments, operators of public, business, and service sites, and individuals (e.g., who get other people’s track records via the leakage of user information through social media) to access people’s private information encourage their behavior of categorizing, judging, and discriminating against people based on their origin and track record? In the second sense, discrimination can happen to people who refuse to or are unable to use the health QR code system, including those who are concerned about privacy and elderly people. Without using the system, people cannot move within and across different cities and are effectively denied access to various kinds of public and commercial services.

Fig. 3  The “TraceTogether” app launched in Singapore. Screenshot by author.

The reason why the problem of discrimination is also linked to the concern about privacy lies in the fact that when the government directed the whole society to massively implement the health QR code system, people tend to be forced to surrender their data privacy to trade their rights of mobility. No matter whether you surrender your data privacy, you can be subject to discrimination: if you do, you can suffer from discrimination based on your privacy; if you don’t, you can suffer from discrimination based on your refusal to surrender.

To deal with the concern of data privacy is very difficult in this case, especially in countries like China with a loose regulation to data privacy protection. There is a fundamental trade-off between the effectiveness of the system of pandemic control and the potentiality of data privacy leakage. As can be easily seen, the failure of finding, positioning, and controlling even one single infected case can cause a huge outbreak. This situation requires the tracking system to be as thoroughly and widely implemented as possible. Nevertheless, the more the system is thoroughly and widely implemented, the higher the risk of data leakage is. Moreover, we can even argue that it is exactly because of China’s loose regulation to data privacy protection and Chinese citizens’ insensitivity towards data privacy concerns that China can use the health QR code system so effectively. For now, we do not have clear answers or solutions to this dilemma. All we can hope and push for is possible legislation procedures to restrict the behaviors of government officials to arbitrarily use the data collected via such systems. In summary, it is obvious that the health QR code is not a technology that can supposedly be effective on its own. It requires a government agency familiar to cybersecurity and digital surveillance, submissive tech firms and the open-platform design of their apps, submissive citizens, and incentivized and powerful governments. Like the case of other technologies, the social and political institutions to support its application is simultaneously the origin of the potential problems it brings to society. How can we balance the benefits and risks? This is a tricky problem.


  1. Hallam Stevens and Monamie Bhadra Haines, “Tracetogether: Pandemic Response, Democracy, and Technology,” East Asian Science, Technology and Society: An International Journal 14, no. 3 (2020): 523-32,
  2. “Quanguo dou zai yong de jiankang ma, yuanlai chuzi tamen zhi shou (The health QR code used all over the country turns out to be development by them),”, January 10, 2021, (accessed February 1, 2021).
  3. “Mayi jituan: Zhifubao guonei huoyue yonghu da 9 yi quanqiu yonghu da 12 yi (Ant Group: The yearly number of active domestic users of Alipay has surpassed 0.9 billion; the number of global active users has reached 1.2  billion),” Sina VR, August 19, 2020, (accessed February 1, 2021).
  4. Wu Yu, “Weixin yuehuo 11.51 yi, gongzhong hao chao 2000 wan! Zhang Xiaolong youyao fang dazhao (The monthly active users of WeChat are beyond 1.151 billion, and the number of public accounts is beyond 20 million! Zhang Xiaolong will conduct major actions again),” China Fund News, January 9, 2020, (accessed February 1, 2021).
  5. Hao, Lei, Fucheng Wan, Ning Ma, and Yicheng Wang. “Analysis of the development of WeChat mini program.” In Journal of Physics: Conference Series, vol. 1087, no. 6, p. 062040. IOP Publishing, 2018.
  6. Stevens and Haines, “Tracetogether: Pandemic Response, Democracy, and Technology,” 523-32.
  7. HKSAR, “LeaveHomeSafe Mobile App,” accessed February 1, 2021,
  8. National Hygiene and Health Commissions, National Healthcare Security
    Administration and National Administration of Traditional Chinese Medicine, “Guanyu shenru tuijin ‘hulianwang + yiliao jiankang’ ‘wuge yi’ fuwu xingdong de tongzhi (The notification on deeply enhancing the ‘Internet + medical health’ ‘five one’ service action),” December 4, 2020, (accessed February 1, 2021).
  9. Yingyi Qian and Chenggang Xu, “Why China’s Economic Reforms Differ: The MForm Hierarchy and Entry/Expansion of the Non-State Sector.” Economics of Transition and Institutional Change 1, no. 2 (1993): 135-70,; Chenggang Xu, “The fundamental institutions of China’s reforms and development.” Journal of Economic Literature 49, no. 4 (2011): 1076-1151.