Perioperative nonsteroidal anti-inflammatory drugs and the risk for anastomotic leakage in patients undergoing major gastrointestinal surgery: a retrospective cohort study Authors: Haoyun Zhang, Feng Zhao, Ting Zhang, Likai Shi, Shiyi Han, Xuecai Lv, Hao Li, Jingsheng Lou, Jiangbei Cao, Weidong Mi, Yanhong Liu Published: 2025 ABSTRACT BackgroundNon-steroidal anti-inflammatory drugs (NSAIDs) are widely used for postoperative pain management; however, their safety in patients at risk for anastomotic leakage remains uncertain. This study evaluated the association between perioperative use of NSAIDs and anastomotic leakage after major gastrointestinal surgery.DesignRetrospective cohort study.SettingChinese People’s Liberation Army General Hospital, Beijing, China.PatientsIndividuals (n = 18,312) who underwent major gastrointestinal surgery between January 2008 and August 2019. Patients were divided into two groups: NSAIDs (n = 8405); and non-NSAIDs (n = 9907). Propensity score matching (PSM) was used to balance baseline characteristics between the two groups, resulting in 6458 patients per group.InterventionsLogistic regression and subgroup analysis were employed to evaluate the association between NSAID use and postoperative outcomes, as well as the interaction with other risk factors.ResultsPSM analysis revealed that perioperative NSAIDs use was associated with a higher risk for anastomotic leakage (odds ratio 1.95, 95% confidence interval 1.48–2.57; P < 0.001). Multivariate logistic models confirmed this association. After classifying NSAIDs into non-selective cyclooxygenase (COX) inhibitors and selective cyclooxygenase-2 (COX-2) inhibitors, multivariate logistic regression analysis demonstrated that selective COX-2 inhibitors were significantly associated with an elevated risk for leakage, whereas non-selective COX inhibitors exhibited no such association.ConclusionsPerioperative use of selective COX-2 inhibitors, but not non-selective NSAIDs, was associated with an increased risk of anastomotic leakage after major gastrointestinal surgery. Therefore, caution should be exercised when selective COX-2 inhibitors are administered to these patients.Supplementary InformationThe online version contains supplementary material available at 10.1186/s12871-025-03560-7. Introduction Effective postoperative analgesia is important for overall postoperative recovery. Due to the complexity of postoperative pain, multimodal analgesia is recommended to maximise analgesia while minimising side effects through a combination of multiple drugs. Non-steroidal anti-inflammatory drugs (NSAIDs) play a major role in Enhanced Recovery after Surgery (ERAS) protocols and are widely used in the perioperative period for their anti-inflammatory and analgesic properties [1]. However, NSAIDs have well-known adverse effects on the gastric mucosa, renal, cardiovascular, hepatic, and haematological systems. The most common complications are gastrointestinal, including gastritis, ulcers, perforation, and enteropathy. There is increasing concern about the safety of NSAIDs in patients undergoing gastrointestinal surgery who have a high risk for anastomotic leakage. NSAIDs are associated with an increased risk for postoperative anastomotic leakage in patients undergoing colorectal surgery [2, 3]. However, the results of some of these studies remain controversial. The risk for anastomotic leakage after bowel surgery was not significantly increased in a recent meta-analysis of six randomised controlled trials (n = 480) of patients receiving at least one dose of NSAIDs or cyclooxygenase-2 (COX-2) enzyme inhibitors within 48 h of surgery [4]. In the current consensus statement for ERAS in gastrointestinal surgery, a multimodal analgesia regimen based on the routine use of NSAIDs has been recommended [5]. Meanwhile, it has been demonstrated that other factors, such as sex, history of radiotherapy, surgical sites, and surgical duration, are related to the risk for anastomotic leakage in patients undergoing gastrointestinal surgery. The joint association between NSAIDs and risk factors for postoperative anastomotic leakage remains unclear. Therefore, further research is needed to clarify the risk for NSAIDs use and provide further evidence supporting the rational use of NSAIDs in these patients. In this study, we hypothesized that the perioperative use of NSAIDs was associated with an increased risk for anastomotic leakage in patients undergoing gastrointestinal surgery and tested this hypothesis using an established postoperative database. We further examined the impact of NSAIDs in patients with additional risk factors for anastomotic leakage, as well as the relationship between the use of selective COX-2 inhibitors and non-selective COX inhibitors and the incidence of leakage. Methods This retrospective cohort study used information obtained from a perioperative database at the Chinese People’s Liberation Army General Hospital (Beijing, China) [6]. This database contains information for consecutive patients with electronic health records of surgical, anaesthetic, and treatment information during hospitalisation between January 2008 to August 2019. This database study was approved by the Institutional Ethics Committee of the Chinese People’s Liberation Army General Hospital (No. S2019-311–03) and was conducted in accordance with the Declaration of Helsinki. The requirement for written informed consent was waived due to the retrospective nature of the study. This study adhered to the Strengthening the Reporting of Observational Studies in Epidemiology (STROBE) guidelines and is reported accordingly. Study population and setting Information from patients who underwent major gastrointestinal surgery was initially screened using a perioperative retrospective database. The inclusion criteria were as follows: age ≥ 18 years; underwent major gastrointestinal surgeries with a duration >60 min; and received general anaesthesia. Major surgery was defined as organ removal or normal surgical anatomy change after peritoneal access, as previously reported [7], including procedures creating any gastrointestinal anastomosis. This study mainly included patients who underwent gastrectomy, small-bowel resection, and colorectal resection. Patients were included only if the primary indication for surgery was a gastrointestinal pathology. Patients with an American Society of Anesthesiologists (ASA) classification of IV or greater, those with surgeries involving non-gastrointestinal organs, including the liver, bile duct, uterus, and ovary, and those missing data for >5 variables were excluded [8]. Among patients who underwent multiple surgeries during the study period, only the first eligible surgery was considered. Exposure and clinical outcomes NSAIDs were identified from hospital patient records. Patients who received NSAIDs, including both selective and non-selective COX-2 NSAIDs, during the intraoperative period and within the first three postoperative days were classified into the NSAIDs group. To account for heterogeneity in drug potency and dosing schedules, all NSAID agents were converted to a standardized exposure metric, calculated as the ratio of the total received dose to the recommended maximum adult daily dose for each drug [9]. The continuous variable of standardized NSAID exposure was divided into three groups based on sample tertiles, corresponding to low (< 0.25), moderate (0.25–0.75), and high (≥ 0.75) exposure levels. The primary outcome was the effect of perioperative NSAIDs use on postoperative anastomotic leakage. Anastomotic leakage was defined as a clinically diagnosed leak at the site of intestinal anastomosis requiring ≥ 1 of the following interventions: antibiotic treatment; percutaneous drainage; reoperation with a new anastomosis; reoperation with proximal diversion; or reoperation with an end stoma [10]. The diagnosis of anastomotic leakage was based on medical records, and screening was performed independently by two physicians (ZF and ZH). Inconsistent cases were identified after discussion with a supervising physician (LY). Secondary outcomes included the occurrence of major postoperative bleeding, acute renal injury, hospitalisation days after surgery, occurrence of secondary surgery, and death. Major bleeding was defined as patients receiving >2 units of blood transfusion after surgery, or those with a decrease in haemoglobin level of 20 g/L after surgery within 24 h. Acute kidney injury (AKI) was defined as a significant increase in serum creatinine level by ≥ 26.5 µmol/L within 48 h or a 1.5-fold increase in serum creatinine from the preoperative baseline within seven days after the surgery. Patients were diagnosed with AKI if they fulfilled the Kidney Disease Improving Global Outcomes (i.e., “KDIGO”) criteria [11, 12]. Secondary surgery was defined as reopening of a recent laparotomy, exploratory laparotomy, diagnostic laparoscopy, operative drainage of an abscess, and drain placement. Variables Clinical characteristics, including sex, age, body mass index (BMI), coexisting diseases, malignancy status, and types of surgery, were extracted from medical records. Age was treated as a binary variable and elderly individuals were defined as those ≥ 65 years of age. BMI was divided into four categories: underweight (< 18.5 kg m–2), normal weight (18.5 kg m–2 ≤ BMI < 25 kg m–2), overweight (25 kg m–2 ≤ BMI ≤ 30 kg m–2), and obesity (BMI >30 kg m–2) according to the international criteria for overweight and obesity [13]. Perioperative data included anaesthesia method, operative duration, ASA classification, estimated blood loss, blood transfusion volumes, and fluid infusion. The results of the most recent laboratory investigations before surgery were collected, including total bilirubin, albumin, serum creatinine, prothrombin time, and haemoglobin levels. Tumor staging was based on the American Joint Committee on Cancer (AJCC) 7th edition, which was applicable during the majority of the study period. Statistical analysis Data were analysed using SPSS version 22.0 (IBM Corp., Armonk, NY, USA) for Windows (Microsoft Corp., Redmond, WA, USA) and R software version 4.1.1 (R Foundation for Statistical Computing, Vienna, Austria). Normally distributed continuous variables are expressed as mean ± standard deviation (SD) and compared using an unpaired, two-tailed t test. Otherwise, data are expressed as median (interquartile range, IQR) and compared using the Mann–Whitney U test. Categorical variables were compared using the chi-squared test or Fisher’s exact test. Categorical data are summarised as number (proportion). Missing data were minimal (< 5% for all included variables) and were not expected to materially influence the results. Univariate logistic regression was performed to identify variables associated with postoperative anastomotic leakage (Model 1). Multivariate logistic regression analysis was used to evaluate the clinical effect of NSAID use on anastomotic leakage (models 2, 3, and 4). Covariates included in the multivariable and matching analyses were selected based on clinical relevance and previous evidence regarding potential confounders of anastomotic leakage. These variables covered demographic characteristics (sex, age, body mass index), general health status (ASA classification, comorbidities such as hypertension and diabetes), baseline renal and hepatic function, oncologic and surgical factors (tumor malignancy, colorectal versus non-colorectal, operative time, intraoperative blood loss, transfusion, and fluid administration), and perioperative analgesic management (paracetamol use and anesthesia type). The selection aimed to account for patient-, disease-, and surgery-related factors that might influence both NSAID exposure and postoperative outcomes. Differences with a two-sided P < 0.05 were considered to be statistically significant. Propensity score matching Propensity score-matching (PSM) analysis was used to reduce the potential confounding effects of patients clinical baseline characteristics in the NSAIDs versus (vs.) non-NSAIDs groups. Propensity scores were generated using logistic regression analysis. After propensity score adjustment, patients in the NSAIDs and non-NSAID groups were randomly matched at a ratio of 1:1 using the greedy nearest neighbour matching approach with a caliper width of 0.02. Kernel density plots of the propensity scores were used to examine the equivalence between matched patients. The standardised mean difference (SMD) was reported to evaluate baseline differences between the two groups, in which a value < 0.1 indicated minor differences. Subgroup analysis Subgroup analysis was further used to appraise the association between perioperative use of NSAIDs and anastomotic leakage in subgroups of the original cohort stratified according to sex, history of chemoradiotherapy, surgical approach, type(s) of surgery, operative duration (< 3 h vs. ≥ 3 h), and paracetamol use. Dose–response analysis To explore the dose–response relationship between perioperative NSAID exposure and the risk of anastomotic leak, a multivariable logistic regression model incorporating restricted cubic splines for standardized total NSAID dose was fitted. The model was adjusted for the following covariates: age, sex, body mass index (BMI), ASA physical status, hypertension, diabetes mellitus, chemoradiotherapy, malignancy, colorectal surgery, blood transfusion, preoperative laboratory parameters (creatinine, hemoglobin, albumin, total bilirubin, and prothrombin time), estimated blood loss, intraoperative fluid volumes (crystalloids and colloids), anesthesia method, paracetamol use, emergency surgery, and surgery year. Predicted probabilities and 95% confidence intervals were derived from the adjusted model and visualized using spline curves. Results Clinical characteristics Data from 21,108 consecutive patients, who underwent gastrointestinal surgery between January 2008 and August 2019, were included. A flow-diagram of the patient selection process is presented in Fig. 1. After applying the inclusion and exclusion criteria, 18,312 patients were eligible for analysis, of whom 6007 (32.8%) were female, with a median age of 60 years (IQR 51–68 years). Of these eligible patients, 8405 (45.9%) received NSAIDs perioperatively (NSAIDs group), while the remaining 9907 did not receive NSAIDs (non-NSAID group). The most commonly used NSAIDs after the index surgery was parecoxib sodium (n = 4760). There were 1464 (8.0%) patients who were treated with ≥ 2 types of NSAIDs. A detailed list of the NSAIDs used perioperatively is provided in Supplementary Table S1. The baseline characteristics of the two groups are summarised in Table 1. Fig. 1Flow diagram of study participants. NSAIDs, non-steroidal anti-inflammatory drugs. ASA, American society of anesthesiologists physical status classification system Flow diagram of study participants. NSAIDs, non-steroidal anti-inflammatory drugs. ASA, American society of anesthesiologists physical status classification system Table 1Baseline characteristics of unadjusted cohort and propensity score-matched cohortCharacteristicsUnadjusted cohortPSM adjustedNon-NSAIDsNSAIDsP valueSMDNon-NSAIDsNSAIDsP valueSMDn=9907n=8405n=6458n=6458Male, n(%)6659 (67.2)5646 (67.2)0.9660.0014366 (67.6)4346 (67.3)0.7210.007Age≥65, n (%)3394 (34.3)2861 (34.0)0.7670.0052248 (34.8)2235 (34.6)0.8240.004BMI, n(%)<0.0010.0670.9040.013Underweight (<18.5)555 (5.6)372 (4.4)292 (4.5)309 (4.8)Normal weight (18.5 ≤BMI < 25)5863 (59.2) 4980 (59.3)3845 (59.5)3843 (59.5)Overweight (25 ≤BMI≤30) 366 (3.7) 381 (4.5)279 (4.3)273 (4.2)Obesity (BMI > 30)3123 (31.5) 2672 (31.8)2042 (31.6)2033 (31.5)ASA classification (%)<0.0010.2570.0380.045 I 1007 (10.2) 363 ( 4.3)279 (4.3)341 (5.3) II 7582 (76.5) 7184 (85.5)5446 (84.3)5393 (83.5) III 1318 (13.3) 858 (10.2)733 (11.4)724 (11.2)Hypertension (%) 2151 (21.7) 2228 (26.5)<0.0010.1121669 (25.8)1626 (25.2)0.3970.015Diabetes mellitus (%) 1422 (14.4) 1392 (16.6)<0.0010.0611056 (16.4)1036 (16.0)0.6500.008Chemoradiotherapy (%) 1671 (16.9) 2505 (29.8)<0.0010.311561 (24.2)1610 (24.9)0.3260.018laboratory parametersSerum creatinine, umol/L, median [IQR]71.00 [61.00, 81.30] 73.10 [62.40, 83.30]<0.0010.08972.10 [61.90, 82.50]72.80 [62.30, 82.90]0.0320.002Hemoglobin, g/L (median [IQR])131.00 [114.00, 144.00]130.00 [114.00, 143.00]0.1860.015130.00 [114.00, 144.00]130.00 [114.00, 143.00]0.9360.001Albumin, g/L (median [IQR]) 40.30 [37.70, 42.80] 40.20 [37.80, 42.60]0.8000.00840.30 [37.80, 42.70]40.20 [37.70, 42.60]0.9420.004Total bilirubin, mmol/L (median [IQR]) 9.70 [7.20, 13.00] 9.70 [7.30, 12.90]0.7250.0079.70 [7.20, 12.90]9.60 [7.30, 12.80]0.6040.012Prothrombin time, s (median [IQR]) 13.10 [12.60, 13.60] 13.20 [12.70, 13.70]<0.0010.11813.20 [12.70, 13.70]13.20 [12.70, 13.70]0.0860.009Surgical/Anesthetic parametersMalignancy (%) 8988 (90.7) 7799 (92.8)<0.0010.0765952 (92.2)5943 (92.0) 0.7940.005Surgery approach<0.0010.3960.0670.033Open surgery (%)4875(49.2)2538(30.2)2180 (33.8)2280 (35.3)Minimally invasive surgery (%) 5032 (50.8)5867 (69.8)4278 (66.2)4178 (64.7)Type of surgery0.6330.0070.9300.002Colorectal (%) 5123 (51.7)4377 (52.1)3385 (52.4)3379 (52.3)Non-colorectal (%)4784(48.3)4028(47.9)3073 (47.6)3079 (47.7)Operation time, h (median [IQR])2.98 [2.33, 3.75]3.03 [2.33, 3.83]0.0010.0363.00 [2.32, 3.75]3.00 [2.33, 3.83]0.0510.036Estimated blood loss, mL (median [IQR])150.00 [100.00, 200.00]100.00 [50.00, 200.00]<0.0010.128100.00 [100.00, 200.00]100.00 [100.00, 200.00]0.1040.003Intraoperative Blood transfusion (%) 1328 (13.4) 957 (11.4)<0.0010.061778 (12.0)777 (12.0)1.000<0.001Postoperative Blood transfusion (%) 1683 (17.0) 1548 (18.4)0.0110.0381182 (18.3)1172 (18.1)0.8370.004Colloid infusion, ml/kg/h, (median [IQR]) 3.63 [2.56, 5.01] 3.07 [2.15, 4.27]<0.0010.2933.28 [2.31, 4.47]3.21 [2.28, 4.40]0.1330.001Crystalloid infusion, ml/kg/h, (median [IQR]) 9.47 [7.42, 12.35] 10.54 [8.38, 13.48]<0.0010.24710.07 [7.78, 13.12]10.33 [8.24, 13.10]<0.0010.041Anesthesia method0.0050.051GA (%) 9809 (99.0) 8170 (97.2)<0.0010.1336362 (98.5)6318 (97.8)GA+NB (%)98(1)235(2.8)96(1.5)140(2.2)Propacetamol (%)1632 (16.5)1772 (21.1)<0.0010.118 1327 (20.5)1327 (20.5)1.0000.001Emergency surgery (%),42 (0.4)28 (0.3)0.3830.01519 (0.3)22 (0.3)0.7540.008The data are shown as median (IQR) or n (%)Abbreviations: NSAIDs Non-steroidal anti-inflammatory drugs, GA General Anesthesia, RA Regional anesthesia, SMD Standardized mean differences, IQR Interquartile range, ASA American Society of Anesthesiologists physical status classification system Table 1Baseline characteristics of unadjusted cohort and propensity score-matched cohortCharacteristicsUnadjusted cohortPSM adjustedNon-NSAIDsNSAIDsP valueSMDNon-NSAIDsNSAIDsP valueSMDn=9907n=8405n=6458n=6458Male, n(%)6659 (67.2)5646 (67.2)0.9660.0014366 (67.6)4346 (67.3)0.7210.007Age≥65, n (%)3394 (34.3)2861 (34.0)0.7670.0052248 (34.8)2235 (34.6)0.8240.004BMI, n(%)<0.0010.0670.9040.013Underweight (<18.5)555 (5.6)372 (4.4)292 (4.5)309 (4.8)Normal weight (18.5 ≤BMI < 25)5863 (59.2) 4980 (59.3)3845 (59.5)3843 (59.5)Overweight (25 ≤BMI≤30) 366 (3.7) 381 (4.5)279 (4.3)273 (4.2)Obesity (BMI > 30)3123 (31.5) 2672 (31.8)2042 (31.6)2033 (31.5)ASA classification (%)<0.0010.2570.0380.045 I 1007 (10.2) 363 ( 4.3)279 (4.3)341 (5.3) II 7582 (76.5) 7184 (85.5)5446 (84.3)5393 (83.5) III 1318 (13.3) 858 (10.2)733 (11.4)724 (11.2)Hypertension (%) 2151 (21.7) 2228 (26.5)<0.0010.1121669 (25.8)1626 (25.2)0.3970.015Diabetes mellitus (%) 1422 (14.4) 1392 (16.6)<0.0010.0611056 (16.4)1036 (16.0)0.6500.008Chemoradiotherapy (%) 1671 (16.9) 2505 (29.8)<0.0010.311561 (24.2)1610 (24.9)0.3260.018laboratory parametersSerum creatinine, umol/L, median [IQR]71.00 [61.00, 81.30] 73.10 [62.40, 83.30]<0.0010.08972.10 [61.90, 82.50]72.80 [62.30, 82.90]0.0320.002Hemoglobin, g/L (median [IQR])131.00 [114.00, 144.00]130.00 [114.00, 143.00]0.1860.015130.00 [114.00, 144.00]130.00 [114.00, 143.00]0.9360.001Albumin, g/L (median [IQR]) 40.30 [37.70, 42.80] 40.20 [37.80, 42.60]0.8000.00840.30 [37.80, 42.70]40.20 [37.70, 42.60]0.9420.004Total bilirubin, mmol/L (median [IQR]) 9.70 [7.20, 13.00] 9.70 [7.30, 12.90]0.7250.0079.70 [7.20, 12.90]9.60 [7.30, 12.80]0.6040.012Prothrombin time, s (median [IQR]) 13.10 [12.60, 13.60] 13.20 [12.70, 13.70]<0.0010.11813.20 [12.70, 13.70]13.20 [12.70, 13.70]0.0860.009Surgical/Anesthetic parametersMalignancy (%) 8988 (90.7) 7799 (92.8)<0.0010.0765952 (92.2)5943 (92.0) 0.7940.005Surgery approach<0.0010.3960.0670.033Open surgery (%)4875(49.2)2538(30.2)2180 (33.8)2280 (35.3)Minimally invasive surgery (%) 5032 (50.8)5867 (69.8)4278 (66.2)4178 (64.7)Type of surgery0.6330.0070.9300.002Colorectal (%) 5123 (51.7)4377 (52.1)3385 (52.4)3379 (52.3)Non-colorectal (%)4784(48.3)4028(47.9)3073 (47.6)3079 (47.7)Operation time, h (median [IQR])2.98 [2.33, 3.75]3.03 [2.33, 3.83]0.0010.0363.00 [2.32, 3.75]3.00 [2.33, 3.83]0.0510.036Estimated blood loss, mL (median [IQR])150.00 [100.00, 200.00]100.00 [50.00, 200.00]<0.0010.128100.00 [100.00, 200.00]100.00 [100.00, 200.00]0.1040.003Intraoperative Blood transfusion (%) 1328 (13.4) 957 (11.4)<0.0010.061778 (12.0)777 (12.0)1.000<0.001Postoperative Blood transfusion (%) 1683 (17.0) 1548 (18.4)0.0110.0381182 (18.3)1172 (18.1)0.8370.004Colloid infusion, ml/kg/h, (median [IQR]) 3.63 [2.56, 5.01] 3.07 [2.15, 4.27]<0.0010.2933.28 [2.31, 4.47]3.21 [2.28, 4.40]0.1330.001Crystalloid infusion, ml/kg/h, (median [IQR]) 9.47 [7.42, 12.35] 10.54 [8.38, 13.48]<0.0010.24710.07 [7.78, 13.12]10.33 [8.24, 13.10]<0.0010.041Anesthesia method0.0050.051GA (%) 9809 (99.0) 8170 (97.2)<0.0010.1336362 (98.5)6318 (97.8)GA+NB (%)98(1)235(2.8)96(1.5)140(2.2)Propacetamol (%)1632 (16.5)1772 (21.1)<0.0010.118 1327 (20.5)1327 (20.5)1.0000.001Emergency surgery (%),42 (0.4)28 (0.3)0.3830.01519 (0.3)22 (0.3)0.7540.008The data are shown as median (IQR) or n (%)Abbreviations: NSAIDs Non-steroidal anti-inflammatory drugs, GA General Anesthesia, RA Regional anesthesia, SMD Standardized mean differences, IQR Interquartile range, ASA American Society of Anesthesiologists physical status classification system Baseline characteristics of unadjusted cohort and propensity score-matched cohort The data are shown as median (IQR) or n (%) Abbreviations: NSAIDs Non-steroidal anti-inflammatory drugs, GA General Anesthesia, RA Regional anesthesia, SMD Standardized mean differences, IQR Interquartile range, ASA American Society of Anesthesiologists physical status classification system Association between NSAID use and anastomotic leakage Overall, 296 (1.6%) patients experienced anastomotic leakage, including 204/8405 (2.43%) in the NSAID group and 92/9907 (0.93%) in the non-NSAID group. The all-cause mortality rate during hospitalisation was 0.2% (31/18,312), and the mortality rate in patients with anastomotic leakage was 2.0% (6/296), which was significantly higher than that in patients without anastomotic leakage (P < 0.001). The clinical characteristics and management of patients with anastomotic leakage are summarised in Supplementary Table S2. Univariate and multivariate logistic regression analyses were used to evaluate the association between perioperative NSAIDs use and anastomotic leakage. Univariate logistic regression analysis revealed that perioperative use of NSAIDs was associated with anastomotic leakage (odds ratio [OR] 2.65, 95% confidence interval [CI] 2.08–3.41; P < 0.001). Anastomotic leakage was also associated with sex, history of chemoradiotherapy, surgical approach, postoperative blood transfusion, and operative duration in the multivariate analysis (Supplementary Table S3). Three multivariate logistic models were used to further evaluate the association between perioperative NSAIDs use and anastomotic leakage. The perioperative use of NSAIDs was consistently associated with an increased risk for anastomotic leakage in all three models (Table 2 and S2 in the Supplementary Material). Table 2Association between NSAIDs use and postoperative anastomotic leakage using the logistic regression model and propensity score analysisAnalysis methodOR95% CIP valueLogistic regression analysis model 1 (univariate model)2.652.08–3.41< 0.001 model 22.341.82–3.03< 0.001 model 32.131.65–2.77<0.001 model 41.651.25–2.210.001Propensity score analysis (univariate) model PSM1.951.48–2.57<0.001Model 1 was a univariate regression modelModel 2 adjusted for sex, age, BMI, ASA classification, hypertension, diabetes, history of chemoradiotherapy, intraoperative blood transfusion and preoperative laboratory data (serum creatinine, hemoglobin, albumin, total bilirubin, prothrombin time)Model 3 adjusted for all variables in model 2 plus malignancy, type of surgery, postoperative blood transfusion, estimated blood loss, crystalloid infusion, colloid infusion, surgery approach and operation timeModel 4 included all the variables in model 3 plus anesthesia method, paracetamol use, emergency surgery and surgery yearModel PSM was a univariate regression model Table 2Association between NSAIDs use and postoperative anastomotic leakage using the logistic regression model and propensity score analysisAnalysis methodOR95% CIP valueLogistic regression analysis model 1 (univariate model)2.652.08–3.41< 0.001 model 22.341.82–3.03< 0.001 model 32.131.65–2.77<0.001 model 41.651.25–2.210.001Propensity score analysis (univariate) model PSM1.951.48–2.57<0.001Model 1 was a univariate regression modelModel 2 adjusted for sex, age, BMI, ASA classification, hypertension, diabetes, history of chemoradiotherapy, intraoperative blood transfusion and preoperative laboratory data (serum creatinine, hemoglobin, albumin, total bilirubin, prothrombin time)Model 3 adjusted for all variables in model 2 plus malignancy, type of surgery, postoperative blood transfusion, estimated blood loss, crystalloid infusion, colloid infusion, surgery approach and operation timeModel 4 included all the variables in model 3 plus anesthesia method, paracetamol use, emergency surgery and surgery yearModel PSM was a univariate regression model Association between NSAIDs use and postoperative anastomotic leakage using the logistic regression model and propensity score analysis Model 1 was a univariate regression model Model 2 adjusted for sex, age, BMI, ASA classification, hypertension, diabetes, history of chemoradiotherapy, intraoperative blood transfusion and preoperative laboratory data (serum creatinine, hemoglobin, albumin, total bilirubin, prothrombin time) Model 3 adjusted for all variables in model 2 plus malignancy, type of surgery, postoperative blood transfusion, estimated blood loss, crystalloid infusion, colloid infusion, surgery approach and operation time Model 4 included all the variables in model 3 plus anesthesia method, paracetamol use, emergency surgery and surgery year Model PSM was a univariate regression model To further characterize the distribution of anastomotic leakage across surgical categories, leakage occurred most frequently after curative gastrectomy for gastric cancer (1.71%) and colorectal procedures (1.69%), while it was rare after GIST resection (0.32%) and small-bowel resection (0%) (Supplementary Table S4). Leakage was more common in cancer surgeries (1.70%) than in non-cancer surgeries (0.66%) (P = 0.003) (Supplementary Table S5). The baseline oncologic characteristics of malignant cases are summarized in Supplementary Table S6. The majority of patients presented with advanced-stage disease (stage III–IV, 61.8%), most underwent elective oncologic surgery (83.7%), and 24.9% received neoadjuvant chemo- or radiotherapy. Among patients with malignancy, leakage occurred in 1.48% of early-stage (Ⅰ–Ⅱ) and 1.85% of advanced-stage (Ⅲ–Ⅳ) cases, with no significant linear trend across stages (P = 0.075) (Supplementary Table S7). Patients who developed anastomotic leakage also had a markedly longer postoperative hospital stay compared with those without leakage (median [IQR], 35 [26–49] vs. 10 [8–12] days; P < 0.001) (Supplementary Table S8). PSM analysis To further evaluate the effect of NSAIDs on anastomotic leakage, PSM was used to minimise deviations in treatment selection. Before matching, the median propensity score in the NSAIDs group was 0.526 (IQR 0.419–0.626) vs. 0.390 (IQR 0.278–0.524) in the non-NSAID group. The distribution of propensity scores in the two groups before and after matching is presented in Figure S1. After matching, the mean ± SD of the propensity score was similar between the NSAIDs (0.487 ± 0.145) and non-NSAID (0.485 ± 0.143) groups. After PSM, 6458 patients were assigned to each group. All baseline demographic and clinical characteristic variables exhibited a good balance between the two groups, with the SMD of all parameters < 0.1 (Table 1 and Figure S3). Covariate balance was assessed before and after propensity score matching (PSM). Absolute standardized mean differences (ASMDs) were shown for each covariate before matching (gray triangles) and after matching (blue circles). The vertical dashed line at 0.1 represented the conventional threshold for acceptable balance. All covariates achieved adequate balance after matching (ASMD < 0.1). Variables included age, sex, body mass index (BMI), ASA classification, hypertension, diabetes mellitus, chemoradiotherapy history, malignancy, type of surgery (colorectal vs. non-colorectal), intraoperative blood transfusion, postoperative blood transfusion, preoperative laboratory variables (creatinine, hemoglobin, albumin, total bilirubin, prothrombin time), surgery approach, estimated blood loss, crystalloid infusion, colloid infusion, anesthesia method, paracetamol use, emergency surgery, and surgery y A univariate analysis was performed on the PSM-adjusted cohort (Table 2). The correlation between NSAIDs and anastomotic leak remained robust (OR 1.95, 95% CI 1.48–2.57; P < 0.001). Subgroup analysis A subgroup analysis of data from the original cohort was performed using multivariate logistic regression, with the results summarized in Fig. 2 and S2. There were 6007 (32.8%) females. The incidence of anastomotic leakage was 0.9% among females, which was significantly lower than that of males (2.0%). The use of NSAIDs was significantly associated with an increased risk of anastomotic leakage in males (OR 1.71, 95% CI 1.25–2.35; P = 0.001). However, no significant association between NSAID use and anastomotic leak was observed among females (OR 1.38, 95% CI 0.73–2.69; P = 0.334). Fig. 2The joint association of reported risk factors and NSAIDs with anastomotic leakage in patients following major gastrointestinal surgery. The data are shown as n (percentage). Abbreviations: NSAIDs, non-steroidal anti-inflammatory drugs; OR, odds ratio. Models adjusted for age, BMI, ASA classification, hypertension, diabetes, intraoperative blood transfusion, preoperative laboratory data (serum creatinine, hemoglobin, albumin, total bilirubin, prothrombin time), malignancy, postoperative blood transfusion, estimated blood loss, crystalloid infusion, colloid infusion and anesthesia method The joint association of reported risk factors and NSAIDs with anastomotic leakage in patients following major gastrointestinal surgery. The data are shown as n (percentage). Abbreviations: NSAIDs, non-steroidal anti-inflammatory drugs; OR, odds ratio. Models adjusted for age, BMI, ASA classification, hypertension, diabetes, intraoperative blood transfusion, preoperative laboratory data (serum creatinine, hemoglobin, albumin, total bilirubin, prothrombin time), malignancy, postoperative blood transfusion, estimated blood loss, crystalloid infusion, colloid infusion and anesthesia method In subgroup analysis stratified according to history of chemoradiotherapy (yes vs. no), surgery approach (minimally invasive vs. open), types of surgery (colorectal vs. non-colorectal), and operative duration (≥ 3 h vs. < 3 h), these factors were associated with increased risk for anastomotic leakage, and perioperative use of NSAIDs was significantly associated with a higher risk of anastomotic leakage in all these subgroups. A total of 3405 patients used paracetamol perioperatively, accounting for 18.6% of the total population. The incidence of anastomotic leakage (2.2%) was higher among patients who received paracetamol than in those who did not (1.5%). Perioperative administration of NSAIDs in this patient subgroup was also associated with a significantly increased risk for anastomotic leakage. There was also a significant interaction between the surgical approach and NSAIDs for anastomotic leakage (P = 0.007) (Figure S2). The joint association of reported risk factors and NSAIDs with anastomotic leakage (Fig. 2) was examined. In the multi-adjusted models, the combination of these risk factors and NSAIDs was consistently associated with a higher risk for anastomotic leakage. For example, compared with patients who did not receive chemoradiotherapy and NSAIDs, those who did receive both treatments had an OR of 4.34 (95% CI 3.07–6.17; P < 0.001). Comparison of Selective COX-2 Inhibitors and Non-Selective COX Inhibitors. During the perioperative period, 3645 patients received only non-selective COX inhibitors, whereas 3990 patients received only selective COX-2 inhibitors (parecoxib sodium). As shown in the Fig. 3 and Supplementary Table S9, compared with those who did not use NSAIDs, the use of selective COX-2 inhibitors was independently associated with a higher risk for postoperative anastomotic leakage (OR 1.84, 95% CI 1.36–2.49; P < 0.001), whereas non-selective COX inhibitors were not associated with postoperative anastomotic leakage (OR 1.29, 95% CI 0.92–1.83, P = 0.145). Fig. 3Analysis of the impact of selective and non-selective COX-2 inhibitors on the occurrence of anastomotic leakage. Abbreviations: NSAIDs, nonsteroidal anti-inflammatory drugs; OR, odds ratio. Models adjusted for sex, age, BMI, ASA classification, hypertension, diabetes, chemoradiotherapy history, malignancy, type of surgery, intraoperative blood transfusion, postoperative blood transfusion, preoperative laboratory data (serum creatinine, hemoglobin, albumin, total bilirubin, prothrombin time), estimated blood loss, crystalloid infusion, colloid infusion, surgery approach, operation time, anesthesia method, paracetamol use and surgery year Analysis of the impact of selective and non-selective COX-2 inhibitors on the occurrence of anastomotic leakage. Abbreviations: NSAIDs, nonsteroidal anti-inflammatory drugs; OR, odds ratio. Models adjusted for sex, age, BMI, ASA classification, hypertension, diabetes, chemoradiotherapy history, malignancy, type of surgery, intraoperative blood transfusion, postoperative blood transfusion, preoperative laboratory data (serum creatinine, hemoglobin, albumin, total bilirubin, prothrombin time), estimated blood loss, crystalloid infusion, colloid infusion, surgery approach, operation time, anesthesia method, paracetamol use and surgery year Secondary outcomes The effects of perioperative NSAIDs use on secondary outcomes are reported in Table 3. A total of 599 patients (3.3%) experienced major bleeding after surgery. After adjusting for covariates, perioperative NSAIDs use was not associated with major bleeding (OR 1.09, 95% CI 0.91–1.30; P = 0.363). Table 3Analysis of secondary outcomeThe secondary outcomeGroupOR/β95% CIP valueNon-NSAIDsn = 9907NSAIDsn = 8405Logistic regression analysis Major bleeding334(3.4%)265(3.2%)1.090.91–1.300.363 Acute AKI251(2.5%)170(2.0)0.960.78–1.190.724 Secondary operation116(1.2%)108(1.3%)1.280.96–1.700.089 Death12(0.1%)19(0.2%)2.000.93–4.510.081Multivariate linear regression Hospitalization days following surgery12.4511.06−0.91−1.35–0.47< 0.001For each secondary outcome, a multivariate model included all the variables shown in Table 1 was usedAbbreviations: AKI Acute Kidney Injury, NSAIDs Non-steroidal anti-inflammatory drugs, OR Odds ratio Table 3Analysis of secondary outcomeThe secondary outcomeGroupOR/β95% CIP valueNon-NSAIDsn = 9907NSAIDsn = 8405Logistic regression analysis Major bleeding334(3.4%)265(3.2%)1.090.91–1.300.363 Acute AKI251(2.5%)170(2.0)0.960.78–1.190.724 Secondary operation116(1.2%)108(1.3%)1.280.96–1.700.089 Death12(0.1%)19(0.2%)2.000.93–4.510.081Multivariate linear regression Hospitalization days following surgery12.4511.06−0.91−1.35–0.47< 0.001For each secondary outcome, a multivariate model included all the variables shown in Table 1 was usedAbbreviations: AKI Acute Kidney Injury, NSAIDs Non-steroidal anti-inflammatory drugs, OR Odds ratio Analysis of secondary outcome For each secondary outcome, a multivariate model included all the variables shown in Table 1 was used Abbreviations: AKI Acute Kidney Injury, NSAIDs Non-steroidal anti-inflammatory drugs, OR Odds ratio A cute kidney injury (AKI) occurred in 421 patients, perioperative NSAIDs use was not associated with AKI (OR 0.96, 95% CI 0.78–1.19; P = 0.724). Secondary surgery was performed in 224 patients, and NSAIDs use was not associated with the need for secondary surgery (OR 1.28, 95% CI 0.96–1.70; P = 0.089). Furthermore, NSAIDs use was not associated with increased all-cause mortality during hospitalisation (OR 2.00, 95% CI 0.93–4.51; P = 0.081). However, perioperative NSAIDs use was associated with a shorter length of hospitalisation after surgery (P < 0.001). Sensitivity analyses To further assess the robustness of the main findings, standardized NSAID exposure was analyzed across three cumulative dose categories. All perioperative NSAID agents (both selective and non-selective) were converted to a standardized exposure index, defined as the ratio of the total received dose to the recommended maximum adult daily dose for each drug. Patients were categorized into three groups according to the standardized NSAID dose: low (T1, ≤ 0.25), moderate (T2, 0.25–0.75), and high (T3, >0.75). The median [IQR] standardized doses were 0 [0–0] for the low group, 0.50 [0.25–0.50] for the moderate group, and 1.75 [1.50–2.00] for the high group (Supplementary Table S10). The incidence of anastomotic leakage increased across the three groups (0.93%, 2.48%, and 2.30%, respectively; χ² test P < 0.001). In multivariable logistic regression models, both the moderate- and high-dose NSAID groups showed significantly higher risks of anastomotic leakage compared with the low-dose group (adjusted OR = 1.70, 95% CI 1.27–2.28, P < 0.001; and 1.52, 95% CI 1.04–2.22, P = 0.03, respectively). A significant dose–response trend was observed (P for trend = 0.010). When exposure timing was evaluated, both intraoperative-only and postoperative-only NSAID administration were independently associated with higher odds of leakage (adjusted OR = 2.14, 95% CI 1.63–2.83, and OR = 2.38, 95% CI 1.52–3.64, respectively), whereas combined intraoperative and postoperative use yielded an OR of 1.89 (95% CI 1.21–2.89, P = 0.004) compared with non-users (Supplementary Table S11). The restricted cubic spline model further supported a nonlinear dose–response pattern between standardized NSAID exposure and leakage risk (Figure S11). These consistent results across dose levels, exposure timings, and model specifications support the robustness of the association. Similar findings were obtained in additional sensitivity analyses adjusting for intraoperative opioid and corticosteroid administration (Supplementary Table S12), suggesting that perioperative analgesic or anti-inflammatory medication had minimal influence on the observed association. We further stratified the analysis by major upper and lower gastrointestinal procedures. The incidence of anastomotic leakage across colorectal subgroups is summarized in Supplementary Table S13. Perioperative NSAID use was associated with higher leakage risk in curative gastrectomy (adjusted OR = 1.73, 95% CI 1.13–2.69, P = 0.013) and anterior resection (adjusted OR = 1.50, 95% CI 1.02–2.23, P = 0.043). A significant association was also observed in sigmoid/rectosigmoid resections (adjusted OR = 7.59, 95% CI 1.97–38.23, P = 0.007) (Supplementary Table S14). Discussion Intravenous NSAIDs are among the most commonly used drugs after surgery, with effective analgesic effect and are an important component of perioperative acute pain management. Anastomotic leakage is a potentially fatal complication of major gastrointestinal surgeries. Recognizing the risk factors associated with anastomotic leakage will greatly facilitate the early identification of patients who are at high risk for this serious problem. In this study, we found that the perioperative use of NSAIDs was associated with an increased risk for anastomotic leakage in patients undergoing major gastrointestinal surgeries. Research performed in animal models has demonstrated that NSAIDs confound the anastomotic healing process by adversely affecting submucosal collagen fibres and inhibiting epithelial cell migration and mucosal restitution [14, 15]. A study by Bhangu et al. [16], which included a subgroup analysis of selective and non-selective non-steroidal anti-inflammatory drugs, reported that only the non-selective NSAIDs group was associated with an increased rate of anastomotic leakage after surgery, whereas the selective COX-2 inhibitor group did not exhibit any significant change in the rate of leakage. Another meta-analysis reported similar results [3]. In this study population, the most commonly used selective COX-2 inhibitor was parecoxib sodium, which accounted for 56.6% of the NSAIDs group. The most commonly used non-selective COX inhibitor was flurbiprofen axetil (51.4%), an intravenous formulation composed of flurbiprofen axetil with lipid microspheres as a drug carrier that is widely used for pain relief in surgical patients in China [17, 18]. It has been demonstrated that both COX-2 selective inhibitor and non-selective NSAIDs affect the anastomotic healing process by damaging submucosal collagen fibres, the core structure that determines tensile strength, resulting in a decrease in anastomotic tensile strength and reduced rupture pressure [14, 19, 20]. Postoperative use of COX-2 selective inhibitors may also increase the risk for anastomotic leakage after colorectal resection [21]. Selective COX-2 inhibitors have been reported to be associated with the greatest risk for adverse vascular effects. However, concerns also relate to nonselective NSAIDs, especially those with strong COX-2 inhibition such as diclofenac [22]. This effect has been observed even among young and healthy individuals after short-term use [23, 24]. Microthromboses or microemboli, along with the consequent reduction in blood supply to vulnerable anastomotic sites, may serve as pivotal mechanisms driving the adverse effects associated with COX-2 selective NSAIDs. Further studies investigating the different types of NSAIDs, particularly selective NSAIDs, are required. Anastomotic leakage rates vary among different sites of anastomosis [25–30]. Several studies have investigated the correlation between NSAIDs use and complications after colorectal surgery. The results of these studies revealed that NSAID use after colorectal surgery was significantly associated with an increased risk of anastomotic leakage. However, other studies reported negative results in similar settings [10, 31]. In addition, some studies investigating gastroesophageal surgery have indicated that NSAIDs can increase the risk for anastomotic leakage in these patients [2, 32]. In this study population, the proportions of patients who underwent colorectal surgery and non-colorectal surgery, including gastric, oesophageal, and small intestinal anastomosis surgery, were 51.9% and 48.1%, respectively. There was no significant difference in the incidence of anastomotic leakage between colorectal and non-colorectal surgeries. Early perioperative use of NSAIDs was associated with an increased risk of anastomotic leakage in both groups. In contrast, registry-based cohort studies have not shown an increased risk of anastomotic leakage among patients receiving perioperative NSAIDs. One large cohort reported a significantly lower risk of leakage after colorectal cancer surgery, whereas another study observed a lower incidence without statistical significance [33, 34]. Together, these findings suggest that NSAID exposure may not universally increase leakage risk, highlighting the heterogeneity of current evidence regarding its impact on anastomotic healing and long-term outcomes. In addition to NSAIDs, other risk factors were also associated with anastomotic leakage. Similar to a previous study, we found that male sex, history of chemoradiotherapy, laparoscopic surgery vs. open surgery, and duration of surgery were independent risk factors for anastomotic leakage in our multivariate regression models [35]. Male sex, as a risk factor of anastomotic leakage, may be related to the protective effect of oestrogen on the gastrointestinal tract in females [36–38]. Moreover, recent registry studies have suggested that preoperative hormonal status may influence anastomotic healing. In postmenopausal women, exposure to oestrogen-modulating therapy was associated with a reduced risk of leakage, whereas in men, androgen deprivation therapy tended to lower the risk, although not significantly. These findings further support the potential role of sex hormones in the biological mechanisms underlying sex differences in anastomotic leakage [33, 39]. Our study revealed that chemoradiotherapy was significantly associated with anastomotic leakage. In the non-chemoradiotherapy group, the rate of anastomotic leakage was 0.69% in the non-NSAID group and 2.03% in the NSAIDs group. In the chemoradiotherapy group, the anastomotic leakage rate was 2.09% in the non-NSAID group and 3.35% in the NSAIDs group. The use of NSAIDs has been associated with an approximately 1% increase in the occurrence of anastomotic leakage, regardless of chemoradiotherapy. Similar results were also found in the subgroup of type of surgery and operative duration, in which the use of NSAIDs was associated with an increase in the occurrence rate of anastomotic leakage by 1.1%–1.8%. We analysed other side effects associated with NSAIDs and found that perioperative NSAIDs exposure was not associated with postoperative AKI, major bleeding, secondary operation(s), or death. However, the perioperative use of NSAIDs significantly shortened the length of hospitalisation after surgery. The present study had several strengths. First, we included data from 18,312 eligible patients to examine the relationship between NSAIDs use and anastomotic leaks. Second, we used PSM analysis, adjusted for several confounding variables, and achieved consistent results. Third, using subgroup analysis, we investigated how NSAIDs, when combined with other risk factors, affected the occurrence of anastomotic leakage. Our findings revealed an absolute increase in the risk for anastomotic leakage, regardless of the presence of other risk factors. The present study, however, had some limitations, the first of which was its retrospective design and, although PSM was used to adjust for differences in baseline characteristics between the two patient groups, there were potential unbalanced parameters that may have introduced bias. In contrast to the study by Rutegård et al., which was protocol-based and defined NSAID exposure according to each hospital’s postoperative analgesic protocol rather than individual on-demand use, our analysis did not involve standardized institutional protocols for NSAID administration [40]. The potential variability in prescribing practices may therefore have introduced heterogeneity in exposure, but it also reflects real-world clinical practice and enhances the generalizability of our findings. Moreover, information regrading postoperative pain was not included in the database; therefore, it was not possible to analyse the analgesic effect of NSAIDs. This is particularly important because postoperative pain might itself be an early manifestation of an anastomotic leak, which could prompt on-demand NSAID use [41]. Therefore, confounding by indication cannot be fully ruled out and represents a potential source of bias that is difficult to eliminate in retrospective studies. Future prospective studies with standardized analgesic protocols and detailed postoperative pain assessments are warranted to more comprehensively evaluate the relationship between NSAID use, analgesic effect, and postoperative outcomes. This retrospective analysis revealed a significant association between perioperative NSAIDs use and postoperative anastomotic leakage in patients who had undergone major gastrointestinal surgery. There was an absolute increase in the risk for anastomotic leakage regardless of whether patients had other risk factors. COX-2 selective NSAIDs should be used with caution in such patients. Further research investigating the types of NSAIDs, dosage, and duration of prescription for these patients is warranted. Supplementary Information Supplementary Material 1. Supplementary Material 2. Supplementary Material 3. Supplementary Material 4. Supplementary Material 5. Supplementary Material 1. Supplementary Material 2. Supplementary Material 3. Supplementary Material 4. Supplementary Material 5.