Introduction

In recent years, sustainable development has become an important direction for the future development of cities due to various negative impacts such as climate change, natural disasters, and resource crises1. The 17 Sustainable Development Goals (SDGs) issued by the United Nations also emphasize the need for inclusive, safe, risk-resistant, and sustainable cities and human settlements. In order to achieve this goal, countries have proposed a variety of highly competitive urban development strategies, such as sustainable cities, smart cities, urban resilience, green cities, etc.2,3. With the outbreak of the COVID-19 coronavirus, the term urban resilience (Ur) once again stood out among the many urban development pathways as an important concept for assessing sustainable urban development4. Ur is mainly defined as the ability of a city to resist or adapt to some external disturbance and return to normal functioning, which is a reflection of the level of urban integration5.

Existing literature related to urban resilience focuses on four main areas: socio-economic and cultural, local governance, overview studies, and disaster studies6. Among them, socio-economic and cultural-related literature is the most voluminous, focusing on the synergistic relationship between socio-economic domains such as economy, ecology, culture, resources and infrastructure, and urban resilience7. Local governance-related literature mainly argues for the feasibility and effectiveness of specific urban resilience public policies or administrative decisions used to support public policies8. In addition, a large body of literature has conducted overview studies on Ur-related topics such as rural town resilience, disaster resilience, climate change resilience, and infrastructure resilience, emphasizing that the scope of urban resilience research should be broadened and increased9. Finally, disaster research links urban resilience to natural hazards such as floods, climate change, earthquakes, droughts, and hurricanes and explores how cities can increase urban resilience to resist exogenous hazards10.

At the same time, the rapid development of the digital economy (Dig) has also affected all aspects of the city. The advent of multiple disasters has gradually made people realize that the traditional urban development model has many limitations, such as slow speed and low efficiency11. On the contrary, digital development, based on its efficiency and convenience, has gradually become an important path to guide cities towards sustainable development12,13. In this regard, the United Nations has also declared that digital technology-driven urban development is necessary to achieve the 2030 Sustainable Development Goals14,15. Therefore, discussing the relationship between Dig and Ur is important for urban sustainability research.

Existing research on Dig and Ur focuses on the impact of Dig on economic resilience, ecological resilience, social resilience, and infrastructure resilience. Among them, a large amount of literature focuses on the relationship between Dig and economic resilience. For example, part of the literature suggests that both the breadth of coverage and depth of use of Dig have a large positive impact on the economic resilience of cities and that innovative technology and consumption level are two important mediating variables16. Some of the literature suggests that Dig not only promotes regional economic resilience but also has positive spatial spillover effects17. Some of the literature also suggests that digital transformation can effectively improve energy efficiency, which in turn improves economic resilience18. In addition, some literature has also investigated the impact of Dig on urban ecological resilience. For example, part of the literature discusses the role of digitization in resisting climate change, natural disasters, etc., and proposes that digital information research and information technology can effectively enhance the ability of cities to resist environmental risks19,20. On the relationship between digitization and urban social resilience and infrastructure resilience. Part of the literature proposes that the development of Dig has a potential impact on the healthcare system, which can significantly increase the resistance and resilience of cities to external shocks21. Part of the literature suggests that Dig is an important factor in promoting electricity intensity in cities22.

The combination reveals the following possible shortcomings of the existing studies: first, most of the literature has explored economic resilience, social resilience, ecological resilience, and infrastructure resilience, respectively, and among them, economic resilience research is predominant, and very few of them have systematically investigated how the Dig affects the Ur. Second, most of the literature on the Ur is relatively simple in construction, such as the common resilience construction index (RCI), which often uses ten or so indicators to determine the level of regional resilience. Because the concept of resilience covers a wide range, fewer indicators make it difficult to ensure the comprehensiveness of the analysis23,24. Third, most Ur studies emphasize time evolution and linear relationships, while nonlinear and spatial effects are rarely explored.

The contribution of this paper may be reflected in the following aspects: First, it adds a new research perspective. Existing studies pay less attention to the impact of Dig on the overall resilience of cities, and most of them only analyze the economic resilience or ecological resilience of cities. Second, it is innovative in the construction of indicators. In this paper, Ur is measured in detail from four aspects: 11 dimensions and 23 refined indicators. Dig is measured in depth using two dimensions and five refined indicators. Third, it provides a comprehensive and rigorous argumentation idea. On the one hand, this paper adopts alternative indicators, lagged variables, instrumental variables, and other methods to explore the linear relationship between the two. On the other hand, this paper introduces the MMQR model, threshold, and spatial measure to explore the nonlinear relationship between the two. At the same time, this paper analyzes the heterogeneity based on city classes, city clusters, and regions, trying to explore the relationship between the two in a more detailed and comprehensive way.

Theoretical mechanisms and hypothesis development

Dig is a new kind of economic form that has all-factor digital transformation at its core25. Ur refers to the ability of a city to withstand or adapt to certain external disturbances and return to normal functioning, and it is a reflection of the level of urban integration5. Dig affects Ur in four main ways: economic, social, ecological, and infrastructural. Firstly, from an economic point of view, digital technology's utilization can effectively reduce production costs, improve production efficiency, promote economic development, and enhance urban economic resilience. At the same time, the establishment of digital economic platforms improves the convenience of economic and financial activities, breaks through the traditional transaction barriers, and promotes the sustainability of economic development, which in turn enhances the city's economic resilience26. Second, Dig also has multiple impacts on social development. On the one hand, based on permeability and low marginal costs, Dig can reduce geographic constraints, promote the sinking of education and healthcare, and improve social security and stability27,28. On the other hand, Dig can also provide residents with more employment opportunities and a favorable entrepreneurial environment, adjust the income distribution in society, narrow the income gap, and thus enhance the social resilience of cities29. Thirdly, Dig can reduce production energy consumption, reduce pollution emissions, and promote ecological sustainability through system intelligence. In addition, based on big data analysis and digital devices, real-time monitoring of the ecological environment can be realized, reducing the occurrence of pollution incidents and effectively enhancing urban ecological resilience30. Fourth, the development of Dig has led to the intelligent upgrading of traditional infrastructures and facilitated the construction of high-tech infrastructures, such as information networks, to enhance urban infrastructure1.

H1:

Dig can effectively contribute to Ur.

The development of Dig optimizes the urban distribution effect. Dig is centered on a new generation of digital technologies such as cloud computing and big data, and the deep integration of these technologies improves the efficiency of urban resource allocation and contributes to the realization of an individual's own value. At the same time, advanced technology provides opportunities for multiple interests to participate in the distribution, reduces the cost for each subject to participate in the distribution of interests, and is more conducive to the realization of the distribution of fairness and the realization of a win–win situation for multiple subjects. And the optimization of the distribution effect helps cities enhance Ur. On the one hand, fair and friendly distribution helps to improve the wage level of residents in the city, realize ideal income distribution, and ultimately form a strong population aggregation effect to provide reserve power for the city's innovative development. On the other hand, a good distribution effect can promote urban economic growth and reduce urban poverty rates, enhancing the ability to achieve stable social development31.

H2:

Dig can enhance Ur by optimizing distributional effects.

First, Dig has a positive effect on industrial structure upgrades. On the one hand, digital technology can help traditional industries realize industrial digitalization. Traditional industries can make use of digital technology to accelerate the transformation of production factors, which in turn creates a new logic of value generation and distribution through the updating of products or business models and promotes the optimization and upgrading of the industry32. On the other hand, the growing Dig has brought about digital industrialization. The development of Dig has broadened the technological boundaries, promoted the restructuring and differentiation of industries, and formed human-technology-based emerging industries centered on data and information technology, further promoting the upgrading of the industrial structure33.

Meanwhile, the upgrading of industrial structures has a greater positive impact on enhancing the city's ability to resist and adapt to external shocks. On the one hand, industrial diversification can directly diversify the risk of external shocks and reduce the vulnerability of urban systems. On the other hand, according to Marshall's theory of externality and Jacobs' theory of externality, the upgrading of industrial structure and agglomeration can help industrial innovation, and innovative technology and knowledge have externality in the agglomeration area, which can promote the development of the city in the direction of knowledge-intensive and technological specialization34. Innovative and advanced technologies can effectively enhance the resistance of cities to external shocks and improve Ur35.

H3:

Dig can improve Ur by promoting industrial structure upgrades.

Dig itself shows an exponential growth trend, and its impact on Ur is bound to be more than just linear. At the same time, the core of Dig is digital technology, and as with other innovations, the growth and adoption of digital technology continue to follow the technology adoption life cycle, i.e., there are innovators, early adopters, early majority, late majority, and laggards in the diffusion and adoption of digital technology. Based on this, the extent and intensity of the impact of Dig on Ur depends largely on the rate of adoption of digital technology, the extent of digital infrastructure, and the extent to which digital technology enhances the utilization of resources36.

In the early stages of the development of Dig, the construction of digital infrastructure and equipment requires more input from production factors. At this time, the benefits generated by the technology spillover effect are not enough to cover the factors of production consumed in its development. Therefore, with the continuous input and consumption of resources, the city's ability to resist external changes will gradually decrease and face greater development risks37. In the mature stage of Dig, cities can realize high-efficiency production and information breakthroughs through technological means and realize the expansion of Dig scale at a lower marginal cost. At the same time, the integration of digital technology improves the overall resource allocation level of the city, optimizes the city's energy supply structure, and strengthens the ability to cope with systemic risks. Furthermore, cloud computing, big data, and other cutting-edge digital technologies have a greater advantage in risk prediction and real-time monitoring, which can help cities do a good job of risk management and ultimately enhance the resilience of the city38.

H4:

The development of Dig has a nonlinear spillover effect on improving Ur.

There is no unified view on how the development of Dig in cities affects the surrounding cities.

On the one hand, the development of Dig may create a digital divide and bring about uneven development39. According to the Matthew effect, due to different initial endowments, the development of Dig-related infrastructure and technology levels varies. The higher the concentration of digital economy platforms and technologies, the greater the competitive advantage of the city, and the surrounding high-quality factors of production are more concentrated in the city40. In contrast, it is more difficult for neighboring cities to enjoy the dividends brought by Dig, and their development is restricted, resulting in lower Ur. At the late stage of development, the Matthew effect further emerges, the digital divide increases, and the gap between the Ur of neighboring cities and the Ur of core cities further increases41.

On the other hand, the development of Dig can break through the spatial barriers of traditional production, realize the optimization of production factor allocation in a larger geographical scope, reduce the waste of resources at a lower cost, improve the efficiency of factor allocation, and help the rapid and stable development of urban clusters42. At the same time, the development of Dig intensifies the competition and cooperation between cities, which pursue technological innovation and radiate to the surrounding cities, effectively promoting the technological development of neighboring regions. In addition, the breaking down of inter-regional information barriers also contributes to the strengthening of the overall construction of cities and jointly enhances Ur43. To explore what theory is more realistic, this paper presents:

H5:

There is a spatial spillover effect in the impact of Dig on Ur.

Due to different levels of technological and economic development, the development of Dig and its impact on Ur may be different in different regions. Influenced by the initial endowment, there are differences in infrastructure, resource conditions, and policy environments in different cities, which directly lead to different levels of technological and economic development among cities44. Ur consists of social, economic, infrastructural, and environmental factors, and the level of science and technology and economic development play an important role in Ur.

H6:

There is heterogeneity in the impact of Dig on Ur.

Research design

Sample selection and data sources

This paper takes all prefecture-level cities in China as the initial research samples and treats the samples according to the following rules: (1) excluding cities with serious missing data; (2) using interpolation to deal with samples with missing relevant variables.

The digital finance data comes from the "City Digital Inclusive Finance Index" published by the Digital Finance Center of Peking University. The rest of the data comes from the China Urban Statistical Yearbook and the statistical yearbooks published by the government websites of each city. Finally, this paper selects 252 prefecture-level cities in China from 2011 to 2020 as the research sample.

Definition of variables

Urban resilience

Based on reference to the existing literature on Ur measurement, this paper constructs Ur indicators from four dimensions: economic, social, infrastructure, and ecological, and refines the categorization of the four dimensions45.

Economic resilience represents the economic capacity of cities in response to external shocks and is extremely important in Ur46. The economic dimension consists of two main aspects: endowment and structure. Economic endowment means the economic viability of a city, which directly affects the city's resistance and resilience to external changes in the economy47. There are four main indicators: gross domestic product (GDP) per capita, total retail sales of consumer goods, investment in fixed assets, and the number of industrial enterprises above the designated size. Economic structure refers to the economic diversity and rationality of a city's economic development, which mainly affects the city's adaptability and transformation ability after suffering from external shocks48. In this paper, it is expressed as the share of tertiary industry in GDP.

Social resilience is also recognized as a key element in enhancing the resilience of cities, affecting their ability to recover from external shocks49. Social resilience is categorized into five dimensions: stress, vitality, security, stability, and governance. Social stress includes the unemployment rate and population density. The higher the unemployment rate, the lower the resistance of the city to external shocks, while population density increases urban human capital while bringing urban spatial pressure50. Social vitality includes the proportion of employees in the tertiary industry and the number of university students. The stronger the overall strength of the residents, the stronger the city's ability to withstand and adapt to risks. Social security is directly related to the resilience of the city in the event of external shocks, including the number of beds, hospitals, and doctors51. Social stability, which includes the number of unemployed participants and the number of health insurance participants, is an important safeguard for cities to cope with shocks at the market level. In addition, at the governmental level, social governance also plays an important role in Ur, including two indicators, namely, the ratio of public budget revenues to GDP and the ratio of personnel in public administration and social organizations to the total population.

Infrastructure resilience mainly provides support services to maintain the operation of basic urban functions after a shock to the city52. The infrastructure dimension is constructed from two perspectives: supply and drainage. Supply includes two indicators: the electricity consumption of the whole society and the number of buses per 10,000 people. And drainage is expressed in terms of the length of the city's drainage pipes. Refined supply and drainage capacities can speed up the city's recovery and enhance its resilience efficiency53.

Ecological resilience represents the city's ability to cope and recover in the face of natural disasters or anthropogenic pollution risks. The ecological dimension is defined in two ways: greening and governance. Among them, the greening level is expressed by the greening coverage rate of built-up areas, and the higher the greening level, the stronger the ability of the environment itself to resist external shocks54. In addition to relying on the environment's own purification ability, anthropogenic environmental governance capacity also plays an important role in ecological resilience. Anthropogenic governance mainly consists of three indicators, namely the comprehensive utilization rate of industrial solid waste, the rate of harmless treatment of domestic garbage, and the centralized treatment rate of sewage treatment plants, reflecting the efforts made by human beings to enhance ecological resilience55.

Specific indicators under each heading are shown in Table 1.

Table 1 Construction of the Ur index.

In this paper, the entropy weight TOPSIS method is used to obtain the comprehensive index of Ur. The entropy TOPSIS method synthesizes the advantages of the entropy method and TOPSIS method56, and the specific implementation steps are as follows:

First, standardized processing.

$$Y_{it} = \left\{ {_{{\frac{\max (X_{ij}) - X_{ij}}{{\max (X_{ij}) - \min (Xij)}}, \quad X_{ij}{\text{ is a negative indicator}}}}^{{\frac{X_{ij} - \min (Xij)}{\begin{subarray}{l} \max (X_{ij}) - \min (X_{ij}) \\ \end{subarray} }, \quad X_{ij}{\text{ is a positive indicator}}}} } \right.$$
(1)

In the formula, i represents the city, and j represents the measure index. xij and yij represent the index values before and after standardization, respectively.

Second, the information entropy is calculated.

$$E_{j} = - \frac{1}{\ln n}\sum\limits_{i = 1}^{n} {\left[ {\left( {{{Y_{ij}}/{\sum\limits_{i = 1}^{n} {Y_{ij}} }}} \right)\ln \left( {{{Y_{ij}}/{\sum\limits_{i = 1}^{n} {Y_{ij}} }}} \right)} \right]}$$
(2)

Third, construct the weighting index.

$$W_{j} = {{\left( {1 - E_{j}} \right)}/ {\sum\limits_{j = 1}^{m} {\left( {1 - E_{j}} \right)} }}$$
(3)

Fourth, construct the weighting matrix.

$$R = \left( {r_{ij}} \right)_{n \times m}$$
(4)

where, rij = Wj*Yij.

Fifth, determine the optimal and worst scheme.

$$Q_{j}^{ + } = \left( {\max r_{i1},\max r_{i2}, \ldots,\max r_{im}} \right)$$
(5)
$$Q_{j}^{ - } = \left( {\min r_{i1},\min r_{i2}, \ldots ,\min r_{im}} \right)$$
(6)

Sixth, the Euclidean distance between each scheme and the optimal and worst schemes is calculated.

$$d_{i}^{ + } = \sqrt {\sum\limits_{j = 1}^{m} {\left( {Q_{j}^{ + } - r_{ij}} \right)^{2} } }$$
(7)
$$d_{i}^{ - } = \sqrt {\sum\limits_{j = 1}^{m} {\left( {Q_{j}^{ - } - r_{ij}} \right)^{2} } }$$
(8)

Seventh, calculate the relative proximity between each measurement scheme and the ideal scheme.

$$C_{i} = \frac{{d_{i}^{ - } }}{{d_{i}^{ + } + d_{i}^{ - } }}$$
(9)

The higher the relative proximity of Ci, the higher the level of resilience of the city.

Level of digital economy development

Regarding the measurement of the level of urban Dig development, this paper starts with two aspects: internet development and digital finance.

At the level of Internet development, four sub-items are selected to characterize the number of end-of-year cell phone subscribers, the number of Internet broadband access subscribers, the number of employees in the computer services and software industry, and the revenue from the telecommunications business57. Among them, two indicators—the number of end-of-year cell phone users and the number of Internet broadband access users—characterize the level of digital infrastructure construction. The good development of Dig is built on solid infrastructure, and the better the infrastructure, the more efficient the development of Dig58. In addition, the two indicators of the number of employees in the computer services and software industry and the revenue from telecommunication businesses represent the development of the digital industry. The larger the volume of the digital industry, the greater the potential and advantage of the future development of the digital industry, and the higher the level of Dig is59.

The level of digital finance, on the other hand, is indicated by the digital financial inclusion index. The index includes three dimensions, including the breadth of digital financial coverage, the depth of digital financial use, and the degree of digitization of inclusive finance, which can better reflect the level of digital finance in China60.

The Dig is also derived using the entropy weight TOPSIS method.

Mediating variables

In this paper, two mediating variables are selected: distributional effects and industrial structure upgrading.

The distributional effect is represented by the logarithm of total employee wages31. The development of Dig has created a new employment situation and optimized the allocation of human capital. On the one hand, the development of Dig optimizes the labor elements in traditional industries. On the other hand, the emerging industries generated by Dig also increase employment opportunities. When external shocks come, human capital represents the resistance and resilience of urban residents themselves, so this paper takes the allocation effect as one of the mediating variables. In addition, since wages are the most direct measure of the labor force, this paper uses the logarithm of total employee wages to characterize the distributional effect.

Industrial structure upgrading is characterized by the logarithm of industrial value added61. Traditional industries are developed through intelligentization and informatization, which ultimately achieve the optimization of resource allocation as well as the improvement of production efficiency. At the same time, the rapid development of cloud computing, big data, and other emerging technologies has gradually formed a new high-tech industry centered on technology and information. The combination of the two ultimately results in the upgrading of industrial structures. And a good industrial structure in turn promotes economic development, social stability, and the strengthening of infrastructure construction in the city and reduces pollution in the environment. Therefore, this paper adopts industrial structure upgrading as the mediating variable. The value added of industry reflects, to some extent, the transformation of the production process from low-value products to high-value products. Therefore, this paper uses the proportion of industrial added value to regional GDP to characterize the upgrading of industrial structures.

Control variables

Four control variables are selected in this paper: foreign capital use, financial development level, share of science and education inputs, and urbanization rate.

Foreign capital use is an important indicator of Ur, characterized by the logarithm of the amount of foreign capital actually used in the year62,63. On the one hand, the increase in the use of foreign capital is conducive to promoting the development of domestic enterprises towards diversification, increasing economic vitality, and enhancing the economic resilience of the city. On the other hand, the increase in the use of foreign capital may bring high-consumption and high-pollution industries, reducing the city's ecological resilience.

The level of financial development is characterized by the year-end deposit and loan balances of financial institutions over GDP64. The year-end deposit and loan balances represent the idle social funds of the city, and the larger the ratio of year-end deposit and loan balances to GDP, the more idle social funds there are. By expanding the fiscal scale, these funds can be aggregated and used to enhance the city's infrastructure, improving the city's economic resilience and infrastructure resilience.

The ratio of investment in science and education is characterized by the proportion of science and education expenditure to local public budget expenditure, which represents the innovation activity of a city65. Enhancing investment in science and education can optimize industrial structure, promote economic growth, and improve the economic resilience of cities. At the same time, investment in science and education can also improve the quality of the urban labor force and enhance urban social resilience.

Urbanization rate Urbanization is measured using the proportion of non-agricultural population to the total population of the region at the end of the year66. On the one hand, the higher the urbanization rate, the greater the consumption of urban resources, which is prone to resource crises. On the other hand, an increase in the urbanization rate reduces the population density in the countryside, which helps the recovery of forests, grasslands, and other vegetation.

Model setting

Benchmark model

To test the impact of Dig on Ur, we constructed the following model (10):

$$Ur_{it} = \alpha + \beta Dig_{it} + \gamma Controls_{it} + \mu_{i} + \delta_{t} + \varepsilon_{it}$$
(10)

The dependent variable Urit represents the level of resilience of the i city in year t. Digit is the core explanatory variable, representing the level of Dig of the i city in year t. Controlsit is a set of control variables. This paper uses robust standard errors to estimate the regression model.

Channel and mechanism modeling

This paper uses a mediated effects model to test the role of distributional effects and industrial structure upgrading in the mechanisms by which Dig affects Ur. The full-mediated effects model is:

$$Ur_{it} = a_{0} + {\text{ a}}_{1} Dig_{it} + \beta_{1} Controls_{it} + \mu_{i} + \delta_{t} + \varepsilon_{it}$$
(11)
$$T_{it} = b_{0} + \, b_{1} Dig_{it} + \beta_{2} Controls_{it} + \mu_{i} + \delta_{t} + \varepsilon_{it}$$
(12)
$$Ur_{it} = \, c_{0} + \phi T_{it} + \, c_{1} Dig_{it} + \beta_{3} Controls_{it} + \mu_{i} + \delta_{t} + \varepsilon_{it}$$
(13)

where T denotes the mediating variable.

MMQR model

In order to deeply explore the impact of digital economic development on Ur, this paper uses the MMQR model for further analysis67,68. The following model is used to quantify the conditional quantum location scale Qy(τ|R) variable:

$$Y_{it} = \gamma_{i} + \alpha R_{it} + \, (\sigma_{i} + \varphi X_{it} )\mu_{it}$$
(14)

The probabilities are determined by p(σi + φX′it > 0) = 1, while the predictor coefficients are γ, α, σ, and φ. In addition, the k-vector of standard elements of R is denoted by X, which is the characteristic variation with component l, as shown in model (15):

$$X_{l} = X_{l} (R), \quad l = 1,2, \ldots ,k$$
(15)

where Rit is uniformly and independently distributed for all fixed i and t. The general form of model (14) can be written as model (16):

$$Q_{y} (\tau |R_{it} ) \, = \, (\gamma_{i} + \sigma_{i} q(\tau )) \, + \alpha R_{it} + \varphi X{^{\prime}}_{it} q(\tau )$$
(16)

Rit in model (16) is a vector of explanatory variables, including Dig and a set of control variables. And q(τ) represents the τ sample of the quantile, and four samples were evaluated in this study, namely the 25th, 50th, 75th, and 90th. Therefore, the quantile equation in this study is shown in model (17) as follows:

$$min_{q} \sum\limits_{i}^{{}} {\sum\limits_{t}^{{}} {\delta_{\tau } } } (R_{it} - \, (\sigma_{i} + \varphi X{^{\prime}}_{it} ) \cdot q)$$
(17)

Threshold model

The nonlinear effect between Dig and Ur is further examined by a threshold regression model. Among them, the bootstrap method was used to repeat the sampling 300 times to estimate the threshold. The specific model is as follows:

$$Ur_{it} = {\text{ f}}_{0} + f_{1} Dig_{it} I\left( {M_{it} \le Z_{1} } \right) + f_{2} Dig_{it} I\left( {Z_{1} < M_{it} \le Z_{2} } \right) + \cdots + f_{n + 1} Dig_{it} I\left( {M_{it} > Z_{n} } \right) + \mu_{P} + \delta_{I} + \lambda_{Y} + \varepsilon_{it}$$
(18)

Spatial spillover effects

A spatial model (19) is established to further explore the spatial effects of the impact of Dig on Ur, where \(\rho\) is the spatial auto-regressive coefficient and W is the spatial weight matrix.

$$Ur_{it} = \alpha_{1} + \rho WUr_{it} + \eta_{1} WDig_{it} + \eta_{2} Dig_{it} + \gamma_{1} WControl_{it} + \gamma_{2} Control_{it} + \mu_{i} + \delta_{t} + \varepsilon_{it}$$
(19)

In this paper, the geographic inverse distance spatial weight matrix W1 and the geographic inverse distance squared spatial weight matrix W2 are chosen, and they are calculated as follows:

$$W_{1} = \left\{ {\begin{array}{ll} {1/d_{{ij}} } & \quad {i \ne j} \\ 0 & \quad {i = j} \\ \end{array} } \right.$$
(20)
$$W_{1} = \left\{ {\begin{array}{ll} {1/d^{2}{_{{ij}}} } & \quad {i \ne j} \\ 0 & \quad {i = j} \\ \end{array} } \right.$$
(21)

Results

Baseline regression and robustness analysis

Descriptive statistics

Table 2 reports the descriptive statistics of the main variables. In terms of Ur, the standard deviation of Ur level in China (0.062) is small, indicating that the Ur level of most cities in China is close to the average (0.072), and there is not much difference in Ur level nationwide. In terms of Dig development level, the Dig level of the head city (0.797) is much higher than the national average (0.052), which shows that the radiation effect of Dig has not yet been fully released on a national scale.

Table 2 Descriptive statistics of the main variables.

Baseline analysis and robustness tests

Column (1) of Table 3 shows the results of the baseline regression on the impact of Dig on Ur. The results show that the impact of Dig on Ur is positive and significant, and Hypothesis 1 is tested.

Table 3 Benchmark analysis and robustness test.

The baseline regression results may be challenged by potential endogeneity issues. On the one hand, this paper adopts the lagged variable approach to mitigate the endogeneity problem. On the other hand, robustness tests are conducted by replacing the dependent and core explanatory variables. Finally, the paper also utilizes instrumental variables to conduct further tests.

First, one-period lags are applied to all explanatory variables of the baseline model, and the results are shown in column (2) of Table 3. Second, one- and two-period lagged regressions are performed on the core explanatory variables, respectively, and the results are shown in columns (3) and (4) of Table 3. Third, the entropy weight method is used to measure the resilience of Chinese cities. The results are shown in column (5) of Table 3. Fourth, the entropy weight method and principal component analysis are used to measure Dig composite index with replacement analysis, and the results are shown in columns (6) and (7) of Table 3.

Meanwhile, the lagged period of Dig is selected as an instrumental variable in this paper. The two-stage least squares method (2SLS) was used for the estimation. The results show that the Kleibergen-Paap rk LM statistics of the second stage significantly prove that the instrumental variables are correlated with the endogenous variables. Moreover, the F statistic of the first-stage regression is greater than 10, and the instrumental variables are valid. Column (8) of Table 3 shows the final results of the instrumental variable tests.

In summary, the reliability and robustness of Hypothesis 1 are verified, and Dig effectively contributes to Ur.

It is not surprising that hypothesis 1 has been proven. In fact, the development of digital financial inclusion has had a significant effect on China's economic vitality. At the same time, "smart cities" have improved the efficiency of social operations and optimized the construction of infrastructure. And with the application of more digital technologies in low-carbon areas, the urban ecological environment has also been significantly improved. All in all, Dig is influencing Ur in all aspects.

Channel and mechanism analysis

In this paper, we conduct channel and mechanism tests for distributional effects and industrial structure upgrading, and the test results are shown in Table 4.

Table 4 Mechanistic test of Dig on Ur.

Column (2) of Table 4 shows that Dig can positively promote De, and column (3) shows that the effects of Dig and De on Ur are all positive and significant. Columns (2) and (3) clarify the mediating role of De with a mediating effect of 0.018, which accounts for 2.38% of the total effect, and Hypothesis 2 is tested. Similarly, columns (5) and (6) of Table 4 show that Dig positively and significantly improves Ur by promoting industrial structure upgrading, and Hypothesis 3 is tested.

Hypotheses 2 and 3 are verified, clarifying the path of Dig affecting Ur. On the one hand, Dig optimizes urban distribution, stimulates urban innovation, improves the unemployment rate, enhances social stability, and thus raises Ur. On the other hand, Dig reduces the vulnerability of the urban system by promoting the development of advanced industries, improving the structure of backward industries, and guiding the city in the direction of knowledge and technology-intensive development, thus raising Ur.

MMQR analysis

The normality test and cointegration test tables for the data are shown in the Appendix (Supplementary Tables 14), and the results indicate that the data are non-normal and that there is a cointegration relationship between all the explanatory variables. In this paper, the MMQR model that can handle non-normally distributed data is used for analysis, and the results are shown in Table 5.

Table 5 MMQR test.

The results show that the effect of Dig on Ur is positive and significant in all quartiles. In addition, Q0.25, Q0.50, Q0.75, and Q0.90 gradually increase the contribution to Ur from low to high scores. The higher the level of Ur, the greater the contribution of Dig to the improvement of Ur.

After testing the data for slope heterogeneity and cross-sectional dependence, the results are further analyzed in this paper using the Dumitrescu and Hurlin causality tests. The results of the tests are presented in the appendix (Supplementary Table 5). The results of the MMQR regressions allow Hypothesis 4 to be argued.

Nonlinear threshold effect

Based on Hypothesis 4, this paper attempts to further investigate the critical threshold value of the nonlinear effect of Dig on Ur. A threshold regression model is used to estimate the threshold value by applying the bootstrap method with 300 repeated samples. The test results of the threshold effect and threshold value are shown in the appendix (Supplementary Table 6), and the regression results of the threshold model are shown in Table 6.

Table 6 Regression results of the threshold model.

The threshold analysis leads to the following conclusions: First, Dig has a significant dynamic nonlinear spillover effect on Ur enhancement, and Hypothesis 4 is further verified. Second, Dig has a double threshold effect on Ur enhancement. When the level of Dig crosses the first threshold, the spillover effect is weakened, while when the second threshold is crossed, the spillover effect is enhanced. The impact of Dig on Ur enhancement shows a U-shaped change trend.

The argument for Hypothesis 4 brings further thoughts. From the perspective of Ur, since the higher the Ur, the more significant the effect of Dig development on Ur is, then cities with high Ur should vigorously promote Dig development. The Matthew effect of "the strong continue to be strong and the strong get stronger" is very clear here.

From the perspective of Dig, as the level of Dig continues to increase, the promotion effect of Dig on Ur shows a U-shaped change. The possible explanation is that in the early stages of Dig development, such as the arrival of the "Internet Plus Era" and the "Big Data Era", the effects of Dig on all aspects of the city are immediately visible. However, on the one hand, based on the principle of diminishing marginal utility, on the other hand, the development of digital technology has also brought many negative effects. For example, on the economic side, "digital monopoly" and "digital hegemony" are becoming more and more prominent; on the social side, digital security has also become a major hidden danger that cannot be ignored; on the infrastructure and ecological side, behind the powerful computing power of digital technology, its consumption of equipment and electricity brings environmental pollution problems that cannot be ignored. Development is accompanied by a variety of problems. Fortunately, with the growing maturity of digital technology, the above problems have been improved to varying degrees. The government has more and more experience and maturity in dealing with the problems brought about by Dig. At the same time, with the continuous breakthroughs in the bottleneck of digital technology, Dig's "Metcalfe" effect will be more and more significant, and its impact on the Ur will be further enhanced.

Spatial spillover effects

The results of the spatial correlation test show that the Moran I indexes of Dig and Ur are both positive, and the corresponding Moran I indexes are significant at the 5% level in most of the years, as detailed in the Appendix (Supplementary Table 7). This indicates that there is a strong positive spatial autocorrelation for both Dig and Ur and justifies the choice of the spatial regression model in this paper. The SDM spatial model with double fixed effects was selected through the LM test, Hausman test, Wald test, and LR test and determined under two weight matrices. Table 7 reports the results of estimating spatial effects under different spatial weight matrices.

Table 7 Spatial effects under different spatial weight matrices.

The coefficients on Dig and w*Dig in Table 7 show the point estimate effects of spatial spillovers, and in order to address the problem of estimation bias that can result from point estimates69, it is necessary to decompose the total effect into direct and indirect effects. Direct spillovers show the effect of an increase in the level of Dig on the Ur of the region, and indirect spillovers show the effect of Dig growth on the Ur of neighboring regions.

As shown in Table 7, in the two different spatial weight matrices, the SDM model shows significant positive direct and total effects, which indicates that Dig can effectively improve Ur and promote urban resilience, and Hypothesis 1 is further verified. The indirect effect is also significant positive, which shows that Dig can have an impact on Ur in nearby areas through spatial spillover effects. This proves Hypothesis 5.

The argument of Hypothesis 5 identifies the spatial spillover effects of Dig and Ur. On the one hand, there are significant spatial effects of Dig and Ur themselves. A city's development must have an impact on its neighboring areas, and the level of Ur itself cannot be discussed in isolation from the geographical location factor because economic development, social operation, ecological environment, and other factors have synergistic effects in themselves.

On the other hand, there is a significant spatial effect of Dig on Ur. Dig development in a region not only affects the local Ur level but also contributes to the Ur level of neighboring regions.

Heterogeneity analysis

First, based on the "City Business Attractiveness Ranking" published by China's "First Finance", first-tier, new first-tier, second-tier, and third-tier cities are categorized as high-class cities, while other cities are categorized as low-class cities39. Secondly, the cities are categorized into a sample of focused cities and a sample of non-focused cities. According to the Chinese government's specific classification of urban agglomerations in each region of China, this paper categorizes the Beijing-Tianjin-Hebei delta, the Yangtze River delta, the Pearl River delta, the middle reaches of the Yangtze River, the Central Plains, and the Chengdu-Chongqing urban agglomerations as the sample of key urban agglomerations, and the others as non-focused. Finally, the sample is categorized by region into East, West, Central, and Northeast according to the National Bureau of Statistics of China (NBS) economic zones. Details of the heterogeneous city list categorization are shown in the appendix (Supplementary Tables 810).

As a matter of fact, this paper discusses heterogeneity at the three levels of city classes, city clusters, and regions based on the following considerations:

First, Caijing First classifies Chinese cities according to five aspects: business resources, transportation hubs, resident activity, lifestyles, and future plasticity, and the higher the class, the higher the overall endowment. In this paper, cities with higher comprehensive endowments have higher Ur accordingly, and the promotion effect of Dig on Ur may not be more significant. Based on the perspective of city class, this paper tries to explore the promotion effect of Dig on Ur in cities with different levels of comprehensive endowment.

Second, an urban agglomeration is an organic aggregate of multiple cities constituted by a central city as the core and radiating around it. City clusters are closely linked economically, united in terms of social operation, practicing co-construction through urban planning and infrastructure, and ecologically influencing each other. Based on the perspective of urban agglomeration, this paper attempts to explore the comprehensive impact of Dig on the resilience of "urban agglomerations" under the pattern of synergistic development among multiple cities.

Third, while the previous two points mainly focused on cities and urban agglomerations, this paper tries to categorize Chinese cities into four major segments at a more macro-regional level and explore the differences between the segments.

Heterogeneity analysis of direct effects

Results by class are shown in columns (1)–(2) of Table 8. The results of the heterogeneity of direct effects by urban agglomeration are shown in columns (3)–(4) of Table 8. The results by region are shown in columns (5)–(8) of Table 8.

Table 8 Heterogeneity test.

The results show that the impact of Dig on Ur is greater in high-class cities, key city clusters, and eastern regions. On the one hand, Dig can better promote Ur in cities with higher comprehensive endowments, indicating that the higher comprehensive endowment can promote the release of the role of Dig. On the other hand, the effect of Dig on Ur is greater in the synergistic "city agglomerations", which shows that the role of Dig releases a greater effect in the synergistic effect of cities. Meanwhile, looking at the regional segments, Dig in the eastern region promotes Ur more, showing that the digital economy in the coastal region has greater influence.

Heterogeneity analysis of nonlinear spillover effects

The heterogeneity analysis of nonlinear spillovers is detailed in the Appendix (Supplementary Tables 11 and 12).

The results show that, first, cities in high-class cities, key city clusters, eastern regions, and western regions pass the threshold test, further proving that the promotion effect of Dig on Ur is more significant in cities with high comprehensive endowments, city clusters, and coastal regions. Second, from the overall trend, the nonlinear effect of Dig shows a tendency toward decreasing utility.

Combining direct effect analysis and nonlinear effect analysis, it can be seen that the impact of Dig on Ur is heterogeneous, and hypothesis 6 is verified.

Conclusions and recommendations

Taking China as an example, this paper systematically explores the impact mechanism of Dig on China's Ur in three dimensions: linear effect, nonlinear effect, and spatial effect, based on data from 252 cities from 2011 to 2020 and eight sets of samples from city classes, city clusters, and different regions. This study can provide some ideas and inspiration for cities in various countries to enhance Ur and promote sustainable urban development through the development of Dig.

First, the development of Dig should be accelerated. This paper concludes that the development of Dig can contribute significantly to the enhancement of Ur. Consistent with Agboola's study of urban resilience in Nigeria in the digital era, by collecting and analyzing data in real time, timely adjustments can be made to urban development strategies for maximum efficiency and sustainability. This not only contributes to resource conservation but also enhances Nigeria's overall resilience and adaptability in the face of external risks70. Therefore, in order to pursue sustainable urban development, Dig should be seized as a key factor. Specifically, the construction of digital infrastructure should be strengthened first. Digital infrastructure is the cornerstone of Dig, and government departments should increase corresponding construction investment to ensure the stable development of Dig. Secondly, industries should seize the opportunity to promote digital industrialization and industrial digitalization to ensure the long-term stable development of Dig.

Secondly, the role of the urban distribution effect and industrial structure upgrading in Dig to enhance Ur should be emphasized. From the perspective of the channel mechanism, the development of Dig can improve Ur by optimizing the urban distribution effect and promoting the upgrading of urban industrial structures. On the one hand, cities should actively use digital technology to optimize the allocation of production factors. In particular, they should strengthen the utilization efficiency of human capital, improve the fairness and reasonableness of distribution, form a virtuous cycle, and gradually enhance Ur. On the other hand, cities should actively encourage the development of emerging digital industries and improve industrial diversity. At the same time, cities should promote the combination of digital technology and traditional industries to promote the development of cities in the direction of technology-intensive development and enhance the overall resilience of cities.

Third, the focus is on grasping the non-linear impact relationship between Dig and Ur. On the one hand, cities with higher quartiles of Ur should more vigorously develop Dig. On the other hand, the impact of Dig on Ur has an obvious threshold effect, showing a "U" trend. Chatti's findings are similar to this conclusion, suggesting that the environmental impact of digital technology is greater in developed countries than in developing countries71. The non-linear relationship requires cities to pay attention to their own specific development stages and formulate development paths that are differentiated by stage. Specifically, while Dig can positively enhance Ur, prioritizing a comprehensive and long-term development plan is the right way to maximize benefits and achieve sustainable growth.

Fourthly, attention should be paid to the spatial spillover effect of the impact of Dig on Ur. The emergence of Dig is both an opportunity and a challenge, and the digital divide is an issue that should be a concern in spatial effects, which should be addressed to ensure that every city does not fall behind and that the goal of sustainable development can be realized. On the one hand, there is a strong spatial autocorrelation between the levels of Dig and Ur. On the other hand, Dig can effectively enhance the resilience of a city and affect neighboring cities through spatial spillover effects. This conclusion is supported by Hao, who argues that there is a significant spatial synergy effect of Dig on urban sustainability, which is manifested in the spatial spillover effect of "1 + 1 > 2"72. Based on this, the synergistic development strategy between cities should be rationally planned at the macro level, and the development of Dig and the pursuit of Ur should fully take into account the development status of neighboring cities and be integrated into the overall planning system. At the same time, it is possible to establish city clusters for the synergistic development of Dig and Ur, to strengthen information interoperability and resource sharing, and to promote cooperation and competition between neighboring cities.

Fifth, grasp the heterogeneous impact of Dig on Ur. In the heterogeneity test, the impact of Dig on Ur is more obvious in high-class cities, key city clusters, and eastern regions. At the same time, the nonlinear spillover effect of Dig is released more fully in high-class cities, key city clusters, and cities in eastern and western regions. Jiang's research supports this conclusion, and in cities with higher levels of comprehensive development, such as those in the East, cities should capitalize on their own economic resource endowments to move forward with all-round digital transformation more quickly and with higher quality73. On this basis, the paper proposes that cities should fully and accurately recognize their own spatial characteristics and formulate differentiated digital economies and urban development strategies. Specifically, areas where Dig has a better impact on Ur, such as high-class and key cities or eastern regions, should focus on technological breakthroughs in Dig, strengthen investment in high-tech technology research and development, and pursue a higher impact effect. On the contrary, existing cities that are less developed should strengthen infrastructure construction and promote Dig and resilience development on a regular basis as soon as possible.

Although this paper has tried its best to pursue a complete analysis, the article inevitably has some limitations. Firstly, both "Dig" and "Ur" are in the stage of rapid development, and the connotation and extension of the two may change at any time. The research scope adopted in this paper may have timeliness, and the indicators of "Dig" and "Ur" involved in future research may be more comprehensive. Secondly, based on the existing theoretical foundation, this paper has only selected two mechanism variables, namely, urban distribution effect and industrial structure upgrading, while there are many potential variables in practice, such as digital governance, etc., which may be explored more in future research. Finally, although the study includes comparative references to similar studies abroad, the generalizability of the conclusions is limited by the fact that the data related to Chinese cities are only analyzed, and future studies can analyze city samples from multiple countries to discuss Dig and Ur in a larger geographical scope.