Introduction

Global warming has become an increasingly concerning problem, and it will possibly lead to a series of urban health issues including increased ultraviolet radiation, precipitation-related effects, temperature-related effects, vector-borne diseases, and finally air quality, smog-related effects (Bartholy and Pongrácz, 2018). Among the above, those most directly linked to climate change may be associated with temperature-related effects (Chen et al., 2024; Kotz et al., 2024; Lenton et al., 2023). With the urban heat island effects, the phenomenon that urban areas experience a higher temperature than their surrounding non-urban areas because of the storage of cities’ heat, exacerbating the ongoing global warming, extreme heat events start becoming more and more prevalent, threatening urban health (Liu et al., 2022; Tuholske et al., 2021). Recent studies have suggested that under the stress of extreme heat, urban residents suffer from risks including that of diseases and food insecurity (Cai et al., 2024; Daalen et al., 2024; Kazi et al., 2024; Malik et al., 2022; Mora et al., 2022). Apart from these heat-related impacts on urban residents, their dietary health, with the heat-related changes in metabolic mechanism and adaptive dietary changes, also leads us to conjecture it as an important facet (Chen et al., 2022).

Take the previous points together, in the context of climate change, the warming effect exacerbated by the urban heat island effects might cause large impacts on urban dietary health (Cai et al., 2024; Daalen et al., 2024; Kazi et al., 2024; Liu et al., 2022; Malik et al., 2022; Mora et al., 2022; Tuholske et al., 2021). As the global urbanization trend gradually expands the scale and prevalence of urban communities (Jiang et al., 2022; Wei and Ye, 2014), understanding those potential impacts and thus suggesting protections for residents’ dietary health accordingly are crucial, especially if the current trend of global warming continually brings more frequent occurrence of extreme heat events (Luber and McGeehin, 2008).

However, substantiating and offering concrete evidence of extreme heat’s impacts on urban dietary health remains largely irresolvable currently. For one thing, tracking heat-related changes in urban residents’ dietary patterns requires substantial costs for large-scale data collection, and it is difficult to quantify using traditional survey methods. For example, the currently mainstream measuring method of various individual dietary assessment indices not only requires voluntary responses from costly mass questionnaires or interviews, but also lacks a universally acknowledged standard, preventing accurate and robust reflections (Bailey, 2021; Shim et al., 2014; Wingrove et al., 2022). As a result, recent studies on such subject are limited, with most offering indirect insights into heat-related changes in food production or supply but not direct focus on the impacts dietary behaviors (Chen et al., 2022; Dasgupta and Robinson, 2022; Fuglie, 2021; Hasegawa et al., 2021; Kompas et al., 2024). This hinders comprehensive understandings and the development of targeted solutions to address the negative effects of extreme heat on urban residents’ dietary health. Under this circumstance, Online Food Delivery (OFD), with its widespread use and digital nature, presents an unique opportunity for reflection and analysis. In recent decades, the increasingly popular Online-to-Offline (O2O) industry has integrated OFD into essential urban lifestyles (Zhao et al., 2021). In China, for instance, the OFD user base has reached approximately 545 million (Lin, 2024), making it a highly representative source of data. The prevalence and digital nature of OFD, facilitated by online transactions, have led to the accumulation of extensive order data. This data provides a valuable opportunity to overcome the challenges associated with traditional survey methods for investigating the association between changes in heat levels and dietary consumption behaviors.

Despite the high potential of OFD order data, few recent studies utilize it as the medium to investigate the above-mentioned association. For the recent studies which observe urban residents’ diets via their OFD order, most focus on socioeconomic factors instead of heat events (Blow et al., 2019; Janssen et al., 2018; Miura and Turrell, 2014). While some studies examine the association between weather events and OFD consumption patterns (Li et al., 2024; Liu et al., 2021; Yao et al., 2023), specialized analysis on how extreme heat is associated with specific changes in dietary choices is rare. This is because that in these studies, extreme heat is only one of several factors investigated, leading to a lack of in-depth insights and hindering the development of targeted solutions for addressing urban dietary issues caused by extreme heat. For example, although most studies conclude that higher temperatures increase overall OFD consumption, they often overlook heat-related changes in the relative preference for different types of orders. This shift in ordering preferences can significantly affect dietary balance, which has strong implications for dietary health (Rodriguez Paris et al., 2020; Sammugam and Pasupuleti, 2019). To address this gap, we aim to provide a comprehensive, quantitative analysis of OFD ordering patterns, including aspects such as ordering preference structure rather than only the general OFD popularity. Our research will offer a more holistic understanding of the association between extreme heat and urban residents’ OFD ordering patterns and, consequently, on urban dietary health.

To this end, we investigated on a real-world dataset of Beijing’s OFD orders from a popular Chinese OFD platform. Given that Beijing’s OFD has high user popularity and the greatest food diversity supplied in China (Meituan Research Institute, 2020), by analyzing more than 4 million pieces of Beijing’s OFD ordering data across 6 general food categories from June 1st to August 31st of 2019, we aim to offer insights representative of general modern urban living patterns.

In this study, to uncover the comprehensive picture of how extreme heat is associated with changes in OFD consumption patterns and urban health, we analyzed data at three levels: overall, by food category, and at the dish level. By progressively focusing from a macroscopic perspective to the more detailed patterns of changes in ordering preferences at the food category and dish levels, we aim to provide actionable and targeted evidence for cautioning and addressing potential dietary health problems under extreme heat. To reveal associations between temperatures and OFD consumption, we first offer qualitative insights into the trends by a visualization between temperature and OFD sales volume; substantiating this is the statistical analysis using Autoregressive Integrated Moving Average (ARIMA) models, which provide a quantitative reflection of the association between heat and OFD order volumes despite the non-stationary time series of OFD sales data.

With quantitative analysis of OFD sales data, we aim to resolve the large-scale dietary data collection difficulty and the subjectivity problem regarding the concept of dietary health. In the context of urbanization and global warming, we offered objective reflection and prediction of changes in urban residents’ dietary behaviors under the exacerbation of extreme heat. Drawing insights from the results, we suggest prospects for preventing potential dietary imbalance problems and advocate more attention paid to the implications of global warming to urban dietary health issues.

Methods

The statistical analysis is conducted on order data from a popular Chinese OFD platform and meteorological data recorded by the Beijing Observatory. The study population included all consumers in Beijing who ordered OFD services via the investigated OFD platform from June to September in 2019.

Data

OFD order data

OFD order data in this study are recorded by an online food delivery platform in China. This dataset is acquired from (Zhang et al., 2025). We aggregated raw order data on a daily basis, obtaining the volume of delivery orders in the entire day as the key metric for measuring OFD demand. Other metrics used in the study included the order placement time, the food category name, the origin of delivery (restaurant location), and the delivery destination (user’s location). Apart from these basic metrics, based on the locational data we also calculated the delivery distance metric, and based on the time data we also recorded the leisure state (holiday/festival or not) metric. All the real-world order information included above reflects users’ actual dietary behaviors. Additionally, this dataset demonstrates strength as it offers more large-scale and generalizable data than individual-tracking datasets like the one used in (Blow et al., 2019; Miura and Turrell, 2014), and more holistic metrics the crawled dataset used in (Liu et al., 2021).

The dataset encompasses a total of 4,285,046 pieces of orders from 19 types of food listed on the investigated OFD platform (please see the details about the database in the Data Availability section). To avoid redundancy in these 19 types, we classified the ones with similar or related attributes into 6 general food categories (Table 1). The distribution of food-category orders is shown in Table 2.

Table 1 Division of 6 food categories.
Table 2 OFD sales data basics.

One notable feature is the apparent discrepancies among different categories’ popularity, with most OFD services offered in categories like Fast Food, Chinese Traditional Food, and Seafood/BBQ. The significantly higher popularity of these categories might be explained by the fact that they are the common ones that dominate the dining industry. The imbalance might reflect that the OFD services have yet penetrated the diverse dining industry, making the less common categories unavailable in delivery service (i.e. many dishes, like ice cream or frozen yogurt, in the “Sweets” category might be unavailable due to delivery inconvenience).

Meteorological data

The meteorological data used in this study were recorded by Beijing Observatory (2024, Resource and Environment Science and Data Center, CAS). We matched Beijing’s daily OFD order data with the recorded meteorological data. We used daily maximum temperature as the extreme heat indicator metric. Although other meteorological factors like humidity or wind intensity are also shown to have impact on people’s heat perceptions (Amaripadath et al., 2023; Shimazaki et al., 2015), since the exact impacts remain controversial and are complicated by various circumstantial conditions (Potchter et al., 2018; Schweiker et al., 2020), we only take the daily maximum temperature as the direct reflection of heat.

Visualizations

Two groups of visualizations are involved in this study: the comparative visualizations for model construction that will be introduced in the following sub-section, and the visualizations of OFD’s temperature-sales relationship that offer intuitive visual revelations alongside the statistical model results and will be shown in section 3. In all visualizations in this study, the x-axis shows the daily maximum temperatures after rounding down, and the average daily OFD sales on the y-axis are calculated based on averaging sales on days with the same daily maximum temperatures. In all visualizations, we used the normalized “Relative Sales” to reflect the OFD sales, thus avoiding the non-stationary increasing trend from impacting the visual effects. Every normalization procedure is done by subtracting each data point with a linear least-squares fit of itself. The normalization is done only in the visualization part to temporarily control time’s effects, and the following ARIMA statistical analysis does not involve any normalization. Figure 1 shows the effect of this normalization.

Fig. 1
figure 1

Normalized sales on the time series. The normalized sales data on the time series, on which every daily sale is subtracted by its linear fit as shown by the red line in Fig. 2.

Model construction

Figure 2 shows the change of OFD order data in a time series of investigation, exhibiting an apparent increasing trend with respect to time. To avoid time’s potential confounding effect to blur the pattern of associated with heat waves, we come up with using the ARIMA model, which yields reliable reflection on the non-stationary time series (Ho and Xie, 1998; Zhang et al., 2024). Specifically, in investigations of all levels, we first fit the the autocorrelation and then estimated temperatures’ effects in the following way:

$$\begin{array}{l}\left(1-{\varphi }_{1}{B}^{1}-{\varphi }_{2}{B}^{2}-\cdots {\varphi }_{n}{B}^{n}\right){\left(1-B\right)}^{d}{Y}_{t}\\=\left(1-{\theta }_{1}{B}^{1}-{\theta }_{2}{B}^{2}-\cdots -{\theta }_{m}{B}^{m}\right){u}_{t}\end{array}$$
(1)

where φ is the autoregressive parameter, B is the backshift operator, d is the order of differencing, and Yt is the dependent variable, the daily OFD sales volume. θ is the moving average parameter, and ut is the error term. Taking the temperature and other explanatory variables into account, we have

$${Y}_{t}={\beta }_{0}+{\beta }_{1}{X}_{1,t}+{\beta }_{2}{X}_{2,t}+\cdots +{\beta }_{k}{X}_{k,t}+{N}_{t}$$
(2)

where X1,t to Xk,t are explanatory variables, including daily maximum temperature, delivery distance, and leisure, respectively. β denotes the regression coefficients, whose sign indicates positive or negative association we are interested in. Nt is the error term. Altogether with et the white noise considered and the parameters p, d, q determined by selecting the combination with the least Akaike Information Criterion (AIC), we carry out statistical analyses on three respective levels.

Fig. 2
figure 2

Time series analysis. The blue dots indicate the numbers of daily OFD orders on the time series, which present a rather strong linear increasing trend, as fitted by the red simulation line.

The explanatory variables displayed in Eq. (2) are selected with both references to existing studies and our comparative visualizations. We first examined existing literature and found restaurants’ belonged regions, the day’s leisure state, and the time slot of the order are commonly suggested to have strong associations with OFD ordering decisions (Batraga et al., 2018; He et al., 2019; Shanmugam et al., 2021; Zhang et al., 2022). In order to further verify if these variables have strong associations with OFD sales that need to be controlled and included in our regression, we conducted comparative visualizations. In each variable’s visualization, our data was split into two groups and compared. If the patterns of visualizations in a pair show an obvious difference, we reckon this variable as an explanatory variable that should be taken into account in the regression, thus preventing it from confounding our investigation goal: revealing the association between temperature and OFD sales. Overall, we processed and investigated metrics of the average delivery distance, the leisure state, the food category name, and the maximum temperature on a daily basis. By comparing the heat-sales trends in OFD orders classified by these variables, we aimed to find and select the explanatory variables that needed to be controlled in order to isolate out the association between extreme heat and OFD sales. Table 3 shows the basics of these classification.

Table 3 Distribution of OFD orders in 4 classifications.

For each comparison based on the investigated metric, we proposed different grouping standard as follows. Distance is classified by its 50% percentile, respectively (for the calculation of the average delivery distance, each piece of order information’s shortest delivery distance is first calculated based on the longitudinal and latitudinal locations using the Haversine formula (Robusto, 1957), and the daily average delivery distance value will be calculated); Downtown and Outskirt regions are classified by Beijing’s Fifth Ring Expressway (S50) (the geological information is acquired from Beijing Platform for Common Geospatial Information Service (noa, 2024)); Leisure states are classified by determining whether that day is weekend or a legal festive holiday announced by the Chinese government (in our investigated time period from June to September, the Dragon Boat Festival is the only festive holiday being considered); Time Slots are classified by the ordering time, with lunch period 9 a.m.-13 p.m. and dinner period 4 p.m.-8 p.m..

In terms of the division of regions, in which the differences in restaurant density and prosperity might lead to different levels of ordering convenience, in Fig. 3a we observed stronger increasing pattern in outskirt regions. This might be attributed to the lower demand elasticity for delivering services in outskirt regions due to lower convenience. To validate this we examined the differences in orders with longer and shorter distances, as a direct indication of the level of delivering convenience. As shown in Fig. 3b, we did discover that long delivery distance made heat’s association with OFD sales more significant. To this end, we took delivery distance into account in later statistical analyses.

Fig. 3: Comparative visualization in 4 potential explanatory variables.
figure 3

a Region, b distance, c leisure, d time slot distribution, e time slot.

Similarly, observing that the increasing trend is more consistent during non-workdays as shown in Fig. 3c, we identified Leisure as another explanatory variable to be considered. This difference can potentially be attributed to the stronger demand elasticity when people are in leisure, since during non-workdays people generally have more alternatives to OFD services (i.e. higher freedom to dine out or cook) than that during workdays. Under this circumstance, the OFD consumption is associated more strongly with external factors like temperatures.

Eventually, based on the highly aggregated pattern in lunch and dinner periods as shown in Fig. 3d, we examined the heat-sales differences in respectively these two time slots. Different from the previous comparison groups which exhibit relatively strong differences, in Fig. 3e, we found the patterns to be about the same during lunch and dinner. For this reason, we didn’t include time slot as a controlled explanatory variable in the later analyses.

To validate the reliability of our results using the ARIMA model, we also ran the time-varying Cox Proportional Hazards model (Austin, 2012; Davidson-Pilon, 2019) with event variable as ‘the daily sale is higher than the typical value’ by setting the median value of our count variable OFD order sales as the benchmark. We got mostly consistent conclusions, thus reinforcing our conclusions. Specific test results can be checked in Table 3 in the appendix.

All analyses are conducted in Python environment, version 3.12.4. Model constructions and tests in the study are carried out using Python’s statsmodels and lifeline libraries.

Results

In this Results section, we investigated temperature’s association with OFD sales volume by focusing on three scales: overall, by food category, and at the dish level. In such investigations, we demonstrated and quantified the heat-consumption associations, thus presenting statistical evidence for combating the potential problems in urban dietary health in the context of the global warming trend.

Extreme heat’s association with overall OFD sales

We grouped the sales data according to the highest temperature of the day and found that the higher the temperature, the higher the sales. Notably, as introduced in 2.2, this visualization and all following visualizations show the normalized “Relative Sales” to temporarily control the non-stationary linear increasing trend of the OFD sales. Figure 2 presents the time series of OFD sales, showing a linear increase over time (Slope: 98.300; P value: < 0.001). This result is shown in Fig. 4: with temperatures rising, the corresponding average per-day OFD sales exhibit an increasing pattern from 31C to 38C. Specifically, during extreme heat like days with maximum temperatures 37C and 38C, the increase in the OFD orders is especially significant. This positive association and the significant surge during extreme heat primarily confirm the previous assumptions that under heat waves, OFD’s overall popularity grows.

Fig. 4
figure 4

Sales changing with daily maximum temperatures.

We then use the ARIMA model to quantify the accurate association between increasing temperatures and the overall OFD demand. Confirming the qualitative trend in Fig. 4, the ARIMA analysis result substantiated the increasing overall OFD sales during heat waves. As shown in Table 4, the coefficient is 2.093, suggesting a rather significant positive association between daily maximum temperatures and overall OFD demand (see Table 1 in the appendix for the full regression results). However, the P value 0.366 demonstrates that the significance of the positive association might need to be further validated. Hence, we delve more deeply into the food category level.

Table 4 ARIMA test results for overall OFD sales and different food categories.

Extreme heat’s associations with OFD sales for different food categories

To investigate on the basis of Section 3.1, we further decomposed the pattern of temperature’s associations with OFD sales into 6 food categories (see the classification details and standards in Section 2). The 6 qualitative visualizations are shown in Fig. 5. Only Fig. 5b of the “Drinks” category exhibits a significant positive association between the sales volume and the temperatures. Other food categories like Chinese Traditional Food and Sweets, however, show the counter-intuitive negative association; the remaining categories show only insignificant associations that seem to be insufficient to tell whether they are positive or negative.

Fig. 5: Sales changing with daily maximum temperatures for 6 food categories.
figure 5

a Chinese traditional food, b drinks, c fast food, d foreign food, e Seafood/BBQ, f sweets.

Further validated by statistical analysis, we substantiated that the overall increase we found in Section 3.1 is indeed contributed majorly by the “Drinks” category. As shown in Table 4, the coefficient of “Drinks” hits 1.472, with a highly statistically significant p-value lower than 0.001. For other categories, the heat level is either negatively associated with the OFD sales or rather insignificant to cause changes in demand, in accordance with the qualitative patterns shown in Fig. 5 (see Table 2 in the appendix for the full regression results).

Extreme heat’s associations with OFD sales for different dishes

Aiming to understand more specific patterns of the temperature-sales association, we eventually narrowed the analysis down to the level of specific dishes. We looked at the OFD sales data of separated dishes and found out those whose sales experienced the most significant heat-related increase. Figure 6 displays the 10 dishes with highest coefficients for Temperature variable (see the appendix for the specific regression results for these 10 dishes). As shown in Fig. 6, among the 10 dishes that experience greatest increase facing high temperatures, 5 belong to ‘Drinks’ category, which confirms the result found in food-category level regression. More interestingly, four of these drinks are milk tea, a type of sweetened drink popular in China. Other than the sweetened drinks, the rest dishes are scattered in different food categories that present no significant special pattern (Sticky Rice Sweetheart Cake belongs to “Sweets” category, Buckwheat Cold Noodles belongs to “Foreign Food” category, Hunan Style Fried Pork and Fried Eggs with Tomatoes belongs to “Chinese Traditional Food” category, and Quail Egg belongs to “Fast Food” category).

Fig. 6
figure 6

The top 10 dishes of which sales are influenced the most by high temperatures.

Discussion and conclusion

In this study, we adopted ARIMA regression to offer an accurate reflection of the association between changes in heat levels and changes in OFD consumption behaviors, despite the non-stationary increasing trend of the sales in the time series. Associating with the market background, we deduced that the increasing trend might be due to that the investigated year 2019 is known as a year of rapid growth for the Chinese OFD industry, with a 38.9% transaction volume growth compared to the former year (Meituan Research Institute, 2020). Corroborated by statistical evidence, we discovered that extreme heat significantly affects OFD consumption patterns and order structures, which in turn cause implications to urban dietary health. Our major findings are as follows: (1) the temperature is associated with a higher likelihood of increased overall OFD sales with a positive coefficient of 2.093. (2) The increase in overall OFD popularity is driven solely by the “Drinks" category, while other food categories show only a statistically insignificant slight increase or even a decline in sales during extreme heat. (3) Among the top 10 dishes with the greatest increase in sales during extreme heat, five are popular Chinese sweetened drinks. Especially popular is milk tea, which takes four of the 10 dishes.

In the context of global warming, with rising temperatures and more frequent extreme heat events, our findings suggest risks of dietary imbalance if the trend revealed in the study continues or is generalized to a regular basis. Especially regarding our unexpected finding that sweetened drinks experience the greatest surge in demand during extreme heat, its implications of higher sugar intake, if accumulated to become a long-term habit, might cause obesity, type 2 diabetes, and chronic health issues like cardiovascular diseases, as corroborated by many medical studies on a global scale (Lara-Castor et al., 2025; Ma et al., 2022; Malik and Hu, 2022; Rippe and Angelopoulos, 2016). These sweetened-drinks-related diseases have been discovered to exert financial and resource pressure of medical treatments, especially in developing countries (Lara-Castor et al., 2025). Meanwhile, the increment in drinks category might also add to the difficulty of delivery resource allocation, since platforms need to swiftly avoid potential resource idleness and shortage when the demand for drinks quickly increases. Overall, by focusing on the comprehensive associations between extreme heat and OFD ordering patterns, our study offers targeted recommendations to enhance urban dietary health. Considering the potential of quantifying urban dietary health to make objective revelations as shown in this study, we also suggest further research into extreme heat and urban dining behaviors and public health, as well as the refinement of OFD platforms and ecosystems to mitigate the negative health concerns about extreme heat on urban populations.

Specifically, we have two major prospects to promote healthy OFD consumption in the context of global warming. Firstly, we advocate more data-driven investigations of global warming and extreme heat’s connection with urban health. In this study, we found significant patterns between increasing temperatures and urban OFD ordering and, in turn, urban dietary health. However, generally, quantitative investigations of global warming’s relationship with diverse urban social disciplines are limited. In order to prevent and confront the negative impacts of global warming on urban health, more insights are required. On the other hand, aiming for healthier OFD ecosystem, we suggest OFD platforms strengthening guidance for consumers’ dietary health. For example, with targeted advertisement designing schemes or clearer labeling of nutritional information, OFD consumers might be better informed to prevent potential nutritional imbalance problems encountering the trend of global warming.

To our knowledge, this paper is the first to offer data-driven revelation focusing on comprehensive correlations between heat on OFD consumption patterns. By investigating on real-world Beijing OFD order data, we offered insights into changes in urban dietary health in extreme heat, of which the previous studies were limited by the high costs and the lack of scalability of traditional investigation methods. Upon investigation enabled by the large volume of representative OFD order data, we revealed not only changes in patterns of the overall OFD demand but also changes in people’s ordering preferences over different food categories. With quantified associations revealed by ARIMA models, we reflected the changes in OFD ordering patterns in three different levels. Therefore, in the context of global warming, our study demonstrate strong implications on urban dietary health, suggesting potential changes in urban residents’ dietary patterns facing higher temperatures. The conclusions of our study could be referred to when predicting patterns between future temperature increase and urban residents’ dietary behaviors, thus informing preparations to combat potential dietary imbalance.

There are three major limitations in this study. First, we use the metric ’Daily Maximum Temperature’ to reflect extreme heat levels, even though not every order considered in this study occurs at the day’s highest temperature. Second, although we analyze data from one of the largest OFD platforms in China, it remains a single data source. To better validate the generalizability of our findings, future studies could explore heat-related associations across different geographic and socioeconomic contexts. Third, examining micro-level factors to account for individual variability is crucial for understanding OFD consumption behaviors. However, our dataset does not include personal data, limiting our ability to do so. We plan to investigate this aspect when such data becomes available.