figure b

Introduction

Type 2 diabetes is a chronic metabolic disorder that has become a public health problem worldwide. According to the WHO, from 1980 to 2014 the prevalence of diabetes rose from 4.7% to 8.5% in adults and an estimated 1.5 million deaths were directly caused by diabetes in 2019 [1]. In China, the prevalence of diabetes was 12.8% in 2017 [2], with type 2 diabetes accounting for >90% of cases. Prevention and treatment of type 2 diabetes thus present a major challenge for modern society. Melatonin, a natural hormone secreted by the pineal gland, has been considered as a chronobiotic and cytoprotective agent and has therapeutic potential for diabetes [3]. Melatonin treatment has demonstrated beneficial effects in individuals with type 2 diabetes who have coronary heart disease [4], whose diabetes is poorly controlled with metformin [5], or who have insomnia [6]. Typically, melatonin is synthesised from tryptophan (Trp) and regulates circadian and seasonal rhythms [7]. It is also involved in energy and glucose metabolism [8, 9] and immune function [10, 11], and has multiple extraordinary functions such as antioxidant, anti-inflammatory and antitumour activity [12,13,14]. Thus, melatonin is regarded as a cornucopia of the 21st century [14]. In mammals, melatonin receptors are widely expressed at central and peripheral sites such as the immune system, gastrointestinal tract and pancreas [15]. Since the discovery of melatonin in pancreatic tissue, which is the predominant site for insulin secretion [16], investigation of the role of melatonin in diabetes has gained much interest. Genome-wide association studies have identified that the melatonin receptor gene MTNR1B is associated with increased fasting glucose level and risk of type 2 diabetes [17,18,19], and various studies in rodents have indicated a general beneficial role for melatonin in glucose homeostasis [20]. However, studies in different human populations demonstrated a controversial role for melatonin in type 2 diabetes, as both loss-of-function and gain-of-function MTNR1B variant impaired insulin secretion and increased type 2 diabetes risk [21]. In terms of epidemiological studies, a nested case–control study found an association between lower melatonin secretion and higher incidence of type 2 diabetes in American female nurses [22], while a Japanese cross-sectional study found this association only existed in elderly men rather than women [23]. To date, no report has investigated the relationship between melatonin and type 2 diabetes in the Chinese population, and the underlying mechanism linking melatonin to type 2 diabetes is largely unknown.

Increasing evidence indicates that melatonin exhibits important functions in the gut, serving as a multitasking molecule regulating microbial metabolism, circadian rhythms and intestinal mucosal immune cells [24]. In fact, melatonin receptors are widely expressed in the gastrointestinal tract and the levels of melatonin in the gut are at least 400-fold higher than levels in the pineal glands and tenfold to 100-fold higher than levels in serum [25]. Recent studies have reported that melatonin improves metabolic disorders such as lipid dysmetabolism and obesity in mice via modulating gut microbiota [26,27,28], although no report extends to type 2 diabetes. Notably, it has been well recognised that gut microbiota play a key role in the pathophysiology of type 2 diabetes, by modulating inflammation and affecting gut permeability, glucose and lipid metabolism, insulin sensitivity and overall energy homeostasis in the host [29]. Collectively, we hypothesise that gut microbiota may mediate the signals of melatonin and subsequently influence type 2 diabetes.

In the present study, we conducted a cross-sectional case–control study to investigate the association between serum melatonin and risk of type 2 diabetes in a Chinese population. We also examined the role of the gut microbiota in the relationship between melatonin and type 2 diabetes.

Methods

Study population

A cross-sectional case–control study was designed to examine the association between serum melatonin and risk of type 2 diabetes. We recruited 12,750 adults enrolled for health physical examination at the healthcare centres of the Third and Sixth Affiliated Hospital of Guangxi Medical University (GXMU) in Nanning and Yulin City, and from four communities in Guilin City, China during February 2018 to December 2019. Type 2 diabetes was diagnosed according to the 1999 WHO diagnostic criteria [30]: (1) fasting blood glucose (FBG) ≥7.0 mmol/l; or (2) 2 h glucose level in an OGTT ≥11.1 mmol/l; or (3) self-reported previously diagnosed type 2 diabetes with glucose-lowering medication within 2 weeks. Healthy control individuals were defined as being without type 2 diabetes history and having normal glucose (FBG<6.1 mmol/l and 2 h glucose level in an OGTT<7.8 mmol/l). The exclusion criteria were cancer, severe cardiovascular/hepatic/kidney disease, acute infection and mental illness. Participants with missing glucose data or without serum samples were also excluded. The case–control participants were 1:2 matched for sex and age using the propensity score matching (PSM) method. The participant flow chart is shown in electronic supplementary material (ESM) Fig. 1.

To further investigate the role of gut microbiota in the relationship of melatonin and type 2 diabetes, a more rigorously matched case–control study was conducted. To reduce confounding effects, only cases and controls from Fujianyuan Health Care Center of the Third Affiliated Hospital of GXMU recruited in July 2019 and 2020 were included. In addition, those factors known to confound the gut microbiota results, such as sex, age, BMI, alcohol consumption and stool characteristics [31], were 1:2 matched between cases and controls by using the PSM method. The exclusion criteria were extended to chronic digestive disease, history of gastrointestinal surgery and use of antibiotics within 1 month. The flowchart for study participants is shown in ESM Fig. 2.

All participants provided written informed consent. The protocol was approved by the Ethics Committee of GXMU and the study was conducted according to the Declaration of Helsinki guidelines.

Data collection and biochemical measurements

We conducted face-to-face interviews, using a valid questionnaire to collect information on lifestyle (e.g. smoking, alcohol consumption, physical activity and dietary intake), medical history and mediation. Anthropometric measurements were carried out by the local nurses. Overnight fasting blood samples were collected in the morning and serum melatonin was measured using ELISA kits from Shanghai Mlbio Biotechnology Co. (China). Serum levels of glucose, triacylglycerol (TG), total cholesterol (TC), HDL-cholesterol and LDL-cholesterol were measured using Biochemical Analyzer (cobas e601; Roche, Germany).

For the participants recruited for the gut microbiota analysis, 24 h dietary intake and intestinal data were further recorded by a valid questionnaire. After participants had fasted overnight, blood samples and fresh faecal samples were collected in the healthcare centre; faecal samples were immediately placed in liquid nitrogen and stored at −80°C until further analyses. Additional biochemical indexes were measured using Biochemical Analyzer (Shenzhen Mindray BS-2000M, China) for HbA1c, insulin and C-peptide, and ELISA kits (Jiangsu Jingmei Biotechnology Co., China) were used for IL-1β, IL-6, IL-10, IL-17, TNF-α, IFN-γ and lipopolysaccharide (LPS).

Gut microbiota analysis

For those individuals participating in the gut microbiota analysis, bacterial genomic DNA was extracted and the 16S rRNA gene (V4-V5) was sequenced on an Illumina MiSeq platform at TinyGene Bio-Tech (Shanghai) Co (China). High-quality sequence alignments were performed using UPARSE of USEARCH (v8.1.1756) (https://drive5.com/usearch/manual8.1/) and MOTHUR (v1.33.3) (https://mothur.org/). Effective reads from all samples were clustered into Operational Taxonomic Units (OTUs) at 97% identity. α- and β-diversity analyses were employed using MOTHUR (v1.33.3) and R packages (v3.3.2) (https://cran.r-project.org/) [32].

Metabolite analysis

Untargeted LC-MS/MS was used for gut microbial metabolite profiling by an UHPLC system (1290; Agilent, USA) coupled to an Agilent 6545 UHD and Accurate-Mass Q-TOF/MS (6545; Q-TOF, USA). MS was operated in both positive and negative modes. A data matrix was generated, consisting of retention time, mass/charge ratio (m/z) and peak intensity by using ProteoWizard (v3.0.8789) (https://proteowizard.sourceforge.io/) and R package XCMS (v3.18.0) (https://bioconductor.org/packages/3.15/bioc/html/xcms.html). R package ROPLS (v3.18.0) (https://bioconductor.org/packages/release/bioc/html/ropls.html) was used for Orthogonal Projections to Latent Structures Discriminant Analysis (OPLS-DA) after XCMS data processing. The quality of the OPLS-DA model was assessed based on R2 and Q2 scores, and a permutation test was conducted further to validate the model. The metabolites significantly differing in abundance were identified by Benjamini–Hochberg-adjusted p value (false discovery rate [FDR] <0.05) and variable importance for the projection (VIP) ≥1.25). The metabolic pathways analysis was performed using MetPA of MetaboAnalystR (v2.0.1) (https://github.com/xia-lab/MetaboAnalystR) and the significantly affected pathways were detected either by p values from pathway enrichment analysis or by impact values from pathway topology analysis [33].

Statistical analysis

Data are expressed as percentages for categorical variables or as mean ± SD or median (25th to 75th percentile) for continuous variables. Comparisons of variables between two groups were performed with two-tailed t test or Wilcoxon rank-sum test, as appropriate. Differentially abundant features between two groups were analysed using Metastats of MOTHUR (v1.33.3) (https://mothur.org/wiki/metastats/). To identify the microbiota enriched in participants with type 2 diabetes vs control participants, the linear discriminant analysis [LDA] effect size algorithm was used with the significance set at FDR<0.05 and LDA>2.0. Multivariable logistic regression was used to examine the association between serum melatonin and type 2 diabetes risk and the stratified analyses. A multivariable linear regression model was used to test the association between serum melatonin and type 2 diabetes-related traits. The general linear model (GLM) was selected for the analysis of the correlation between type 2 diabetes-related traits and gut microbiota. Only taxa with an average of more than 30 reads per sample were included in the GLM model [34, 35]. Spearman correlation analysis was performed to illustrate the correlation between metabolites and gut microbiota or inflammatory factors. Two-tailed p values <0.05 were considered statistically significant. Stata version 12.0 (StataCorp LP, USA) was used for statistical analysis.

Results

Characteristics of the study population in the association study

A total of 2034 participants were included in the study for exploring the association between serum melatonin and type 2 diabetes risk after matching for age and sex (678 cases vs 1356 controls). Their characteristics are shown in Table 1. The serum levels of melatonin were significantly higher among participants in the control group than among those in the case group (195.55 vs 180.73 pmol/l, p=0.011). However, this difference was only statistically significant in the summer (not in winter.) As expected, the matched cases and controls were not significantly different in sex and age.

Table 1 Characteristics of participants with type 2 diabetes (cases) and matched control individuals

Association between serum melatonin and type 2 diabetes risk

Higher levels of serum melatonin were significantly associated with a lower risk of type 2 diabetes after matching for age and sex (OR 0.84 [95% CI 0.76, 0.92]) and further adjustment for other covariates (OR 0.82 [95% CI 0.74, 0.92]) (Table 2). When the population stratified by sex, the significance persisted in men (p=4.48×10−4) and nearly reached statistical significance in women after adjustment for covariates (p=0.056). When serum melatonin was stratified by tertile, the OR of the highest vs lowest category was 0.75 (95% CI 0.59, 0.95; ptrend=0.018) after adjustment for covariates (Table 2). We also observed that higher levels of serum melatonin were significantly associated with lower FBG levels, such that FBG decreased by 0.25 mmol/l when serum melatonin increased by 1 pmol/l, after adjustment for covariates (β −0.25 [95% CI −0.38, −0.12]) (Table 3).

Table 2 The association between type 2 diabetes and serum melatonin
Table 3 The association between serum melatonin and type 2 diabetes-related traits

Role of gut microbiota in the relationship between melatonin and type 2 diabetes

The characteristics of selected participants

After rigorously matching for age, sex, BMI, alcohol consumption and stool characteristics, and limiting the participants to those recruited in July 2019 and 2020 from Nanning City, 40 cases and 80 controls were included in the analysis. As expected, no significant difference in general characteristics was observed between cases and controls (except for education). However, participants with type 2 diabetes had significantly lower levels of serum melatonin in comparison with control participants (26.74 vs 28.81 pmol/l, p=0.015) (Table 4).

Table 4 Characteristics of selected participants with type 2 diabetes and matched control participants

Alterations of gut microbiota composition in participants with type 2 diabetes with lower melatonin

After 16S rRNA sequencing, a total of 3,818,454 optimised sequences were captured with more than 99.7% coverage. At the phylum level, individuals with type 2 diabetes had a significantly greater abundance of Proteobacteria (10.3% vs 6.4%, p=0.006) (Fig. 1a). Analysis of α-diversity showed that the type 2 diabetes case group exhibited a significantly lower diversity of microbiota compared with the control group (lower Shannon index and higher Simpson index, p<0.05) (Fig. 1b,c). Analysis of β-diversity (weighted UniFrac distance) revealed a significantly smaller distance in the type 2 diabetes case group compared with the control group (p=0.009) (Fig. 1d), indicating that individuals with type 2 diabetes have different gut microbial structure compared with control individuals. According to the bacterial community profiles analysed by the LDA method (LDA>2.0), there were 15 different genera among the two groups, of which 11 were more abundant in the control group (including Coprococcus), and four were more abundant in the case group (including Bifidobacterium; Fig. 2a). Notably, in the case group, the greater abundance of Bifidobacterium was also shown at the class (Actinobacteria), order (Bifidobacteriales) and family (Bifidobacteriaceae) levels (Fig. 2b).

Fig. 1
figure 1

(a) Comparison of relative abundance between the case and control groups at phylum level. (b) Comparisons of α-diversity (Shannon index) between the case and control groups. (c) Comparisons of α-diversity (Simpson index) between the case and control groups. (d) Comparisons of β-diversity (weighted UniFrac distance, Anosim test) between the case and control groups. Data are presented as median with IQR, maximum and minimum in the box plots. *p<0.05, **p<0.01

Fig. 2
figure 2

(a) The abundance of taxa differed between the case and control groups. (b) Taxonomic cladogram by LDA. Red and blue circles, respectively, represent important taxa in the case and control groups; green circles represent taxa without an important role. LDA effect size >2.0 and FDR<0.05 were set for significance. c, class; f, family; g, genus; o, order; p, phylum; s, species

Key phylotypes correlated with melatonin and type 2 diabetes-related traits

At the genus level, we found that out of 48 genera, seven were correlated with melatonin and type 2 diabetes-related traits. Among them, higher abundance of Bifidobacterium was correlated with lower levels of melatonin but higher levels of serum HbA1c and C-peptide (p<0.05). Meanwhile, higher abundance of Coprococcus was correlated with higher levels of melatonin and lower levels of serum IL-1β, IL-6, IL-10, IL-17, TNF-α and LPS (FDR<0.05) (Fig. 3 and ESM Table 1).

Fig. 3
figure 3

Correlation between the key phylotypes and melatonin and type 2 diabetes-related traits. *FDR<0.05 and **FDR<0.01. Test by generalised linear regression (GLM) model. HDL, HDL-cholesterol LDL, LDL-cholesterol; MT, melatonin

Analysis of gut microbiota metabolites

Altered metabolites in type 2 diabetes cases with lower melatonin

By using an untargeted LC-MS/MS approach, a total of 915 and 3890 peaks were detected in the positive and negative modes, respectively. OPLS-DA analysis showed a clear separation between the case and control group in the negative mode (Fig. 4b). The negative model’s predictive accuracy was R2Xcum=0.507, R2Ycum=0.864, and Q2cum=0.227 (R2 p=0.576; Q2 p=0.01) (Fig. 4d), and the positive model’s predictive accuracy was R2Xcum=0.495, R2Ycum=0.176, and Q2cum=0.062 (R2 p=0.859; Q2 p=0.01) (Fig. 4c). Furthermore, according to the criteria that if the red regression line of the Q2 points intersects the vertical axis at or below zero, or if all blue Q2 values to the left are lower than the right one [36], our OPLS-DA models suggested differentially enriched metabolites could be identified by these models (Fig. 4c,d). Finally, a total of 1116 metabolites were identified that were differentially abundant between the type 2 diabetes case group and the control group based on VIP>1.25 and FDR<0.05.

Fig. 4
figure 4

OPLS-DA score plots from positive mode (a) and negative mode (b) with corresponding permutation test plots derived from positive ion mode (ESI+) (c) and negative ion mode (ESI) (d) in LC-MS metabolite profiles of gut microbiota. [1] refers to PC1; R2 refers to interpretability of model; Q2 refers to predictability of model

Metabolic pathway analysis

To further identify the metabolic pathways significantly altered by type 2 diabetes, a summary of pathway analysis is illustrated in Fig. 5a. There were 38 differentially enriched metabolic pathways (all FDR<0.05) and nine with impact value exceeding 0.185. As expected, the Trp metabolism pathway, which is related to melatonin biosynthesis, exhibited an impact value of 0.187 (FDR=0.005). Among the metabolites involved in Trp metabolism pathway, ten showed significant difference between the type 2 diabetes case group and control group (FDR<0.05, VIP>1.25) and correlated with melatonin level (p<0.01) (Table 5).

Fig. 5
figure 5

(a) Summary of pathway analysis by MetPA. The top pathways are ranked by the γ-adjusted p values for permutation per pathway (y-axis) and the total number of hits per pathway (x-axis). The colour graduated from white to yellow, orange and red as the values of both x and y increase. (b) Spearman correlation between the melatonin-correlated genera and those metabolites involved in the Trp metabolism pathway. *FDR<0.05 and **FDR<0.01. (c) Spearman correlation between Trp metabolites and inflammation factors. *FDR<0.05 and **FDR<0.01. (d) Receiver operating characteristic (ROC) curve displaying the classification for type 2 diabetes case and control groups employing the Trp metabolites that were correlated with the melatonin-correlated genera. 5-Hyd, 5-hydroxyindoleacetylglycine; 2-Oxomt, 2-oxomelatonin; Tryp, tryptophanol

Table 5 Metabolites involved in Trp metabolism differ between type 2 diabetes cases and controls and are correlated with melatonin

Relationship between key phylotypes and metabolites involved in Trp metabolism pathway

For the seven genera that correlated with melatonin and type 2 diabetes-related traits, we focused on their relationship with those metabolites involved in Trp metabolism pathway. As shown in Fig. 5b, four genera were correlated with Trp metabolites (FDR<0.05). Coprococcus, which was more abundant in the control group, was correlated with all the nine Trp metabolites, while Bifidobacterium, more abundant in the case group, was correlated with five metabolites. When we further examined the relationship between these Trp metabolites and inflammation factors, we found that all these nine Trp metabolites were significantly correlated with inflammation factors, namely IL-1β, IL-6, IL-10, IL-17, TNF-α and LPS (p<0.05) (Fig. 5c). Interestingly, both the melatonin-related metabolites and genera (Coprococcus and Bifidobacterium) were correlated with inflammation factors, as appropriate (Figs 3 and 5c).

We then tested whether these nine genera-correlated metabolites could be used to predict type 2 diabetes status and found that only 5-hydroxyindoleacetylglycine, 2-oxomelatonin and tryptophanol were potential predictors (p<0.05). The AUC for the three metabolites combined was 0.804 (Fig. 5d). Notably, Coprococcus was negatively correlated with 5-hydroxyindoleacetylglycine, 2-oxomelatonin and tryptophanol, while Bifidobacterium was positively correlated with 5-hydroxyindoleacetylglycine and tryptophanol (Fig. 5b).

Discussion

In the present study, we found that a higher level of serum melatonin was associated with a lower risk of type 2 diabetes, and the underlying mechanism may involve gut microbiota reprogramming, such as alteration in microbial composition and abundance; especially, Bifidobacterium and Coprococcus-mediated Trp metabolites may play an important role.

By using a matched case–control design (n=2034) from a cross-sectional study comprised of 12,750 participants, we described the relationship between serum melatonin and risk of type 2 diabetes in a Chinese population. Previously, by using a urinary marker of melatonin, melatonin secretion was demonstrated to be negatively associated with incidence of type 2 diabetes in American female nurses in a nested case–control study (n=740) [22] and associated with type 2 diabetes risk in Japanese men in a cross-sectional study (n=1096) [23]. This study, using a much larger sample size, provides unique and powerful insights into the relationship between serum melatonin and type 2 diabetes risk. Our findings support the negative association between melatonin and type 2 diabetes risk, with the association being independent of diabetes medication status (ESM Tables 26).

Recently, increasing evidence has emerged that indicates an important role for melatonin in mediating microbial metabolism, circadian rhythms and intestinal mucosal immune function [24]. Through modulating gut microbiota, melatonin prevents obesity and improves lipid dysmetabolism [26,27,28], where obesity and lipid dysmetabolism have been proven as risk factors for type 2 diabetes. However, there is no direct evidence suggesting that melatonin has a mediating effect on gut microbiota and subsequently on type 2 diabetes. For gut microbial studies in humans, a number of factors have been demonstrated to confound the results, such as sex, age, BMI, region, alcohol consumption and stool characteristics [31]. By using a rigorously matched case–control study design, in which no difference was observed between case and control groups for any of the basic characteristics, we found altered gut microbial composition in type 2 diabetes cases with lower serum melatonin level. At the phylum level, the type 2 diabetes case group displayed greater abundance of Proteobacteria. At the genus level, Bifidobacterium and Coprococcus presented different abundance in type 2 diabetes cases vs controls, and both were correlated to serum melatonin and type 2 diabetes-related traits. Bifidobacterium is generally negatively correlated with type 2 diabetes in humans [29], while one double-blind, placebo-controlled randomised study demonstrated a positive correlation with type 2 diabetes [37]. In our rigorously matched case–control study, Bifidobacterium showed greater abundance in type 2 diabetes cases and was positively correlated with HbA1c and C-peptide levels (p<0.05, ESM Table 1), supporting the positive correlation of Bifidobacterium with type 2 diabetes. Coprococcus is a bacterium that produces ‘anti-inflammatory’ short-chain fatty acids and has demonstrated beneficial effects in its host through supplying nutrients, reinforcing the intestinal epithelial barrier function and intestinal immunity [38]. Decreased abundance of such bacteria are commonly observed in disease states [39]. For example, reduced abundance of Coprococcus was observed in individuals with inflammatory bowel disease [40, 41] and pulmonary arterial hypertension [42], while treatment with metformin increased the abundance of Coprococcus in a mouse model of type 2 diabetes [43]. In this study, we also found that Coprococcus was more abundant in control participants and the abundance was negatively correlated with serum levels of IL-1β, IL-6, IL-10, IL-17, TNF-α and LPS, confirming the organism’s potent immunomodulatory and beneficial role in type 2 diabetes.

Interestingly, we found that both Bifidobacterium and Coprococcus were correlated with serum melatonin and type 2 diabetes-related traits, while few studies have documented such relationships. Recently, studies have confirmed the role of melatonin in the gut microbiome–immune system axis, in that melatonin mediates mucosal immune cells and microbial metabolism involving Bacteroidetes fragilis, Prevotella intermedia and LPS [24]. Clinical trials of melatonin in inflammation-related pathologies indicate that oral melatonin could improve bowel symptoms in ulcerative colitis [44] and identified Bifidobacterium as a causal factor of ulcerative colitis [45]. In this study, we found that metabolites involved in the Trp metabolism pathway were correlated with Coprococcus and Bifidobacterium, and were significantly correlated with serum melatonin level. It is well known that the Trp metabolism pathway directly relates to melatonin biosynthesis. It was reported that Trp had profound effects on gut microbial composition and metabolism, as well as on the host’s immune system along the microbiota–gut–immunity axis [46]. Indeed, we also observed a significant correlation between Trp metabolites and inflammation factors including IL-1β, IL-6, IL-10, IL-17, TNF-α and LPS. In human studies, six circulating Trp metabolites (tryptophan, indolelactate, etc.) have been identified as being associated with incidence of type 2 diabetes [47]. Although we did not detect the same Trp metabolites in gut microbiota, when we used the genera-correlated metabolites involved in the Trp metabolism pathway to predict type 2 diabetes status, an AUC of 0.804 supported the important role of Trp metabolites (a combination of 5-hydroxyindoleacetylglycine, 2-oxomelatonin and tryptophanol) in type 2 diabetes. Taken together, our findings indicate that melatonin could be able to modulate the gut microbiota–immunity axis in type 2 diabetes, probably mediated by gut microbial Trp metabolism.

Strengths and limitations

This study has several strengths. First, to our best knowledge, this is the first study to describe the relationship between melatonin and type 2 diabetes in a Chinese population. By using a serum marker of melatonin, with a much larger sample size compared with previous studies and using a matched case–control study design, our findings support the negative association between melatonin and type 2 diabetes risk, consistent with the findings from a nested case–control study and cross-sectional study in American [22] and Japanese populations [23]. In addition, due to human lifestyle and physiological variables exerting differential effects on the microbiota [31], we designed a rigorously matched case–control study to explore the role of gut microbiota in the relationship between melatonin and type 2 diabetes. As expected, there was no difference between the case and control groups when comparing all the basic characteristics. These design features made it possible to explore the role of gut microbiota in the relationship between melatonin and type 2 diabetes independently. We found that individuals with type 2 diabetes presented with altered gut microbiota (especially, Bifidobacterium and Coprococcus) and lower serum melatonin levels, suggesting that melatonin-correlated genera and mediated Trp metabolites may play an important role in this relationship.

A limitation of this study is that no causal relationship was described between serum melatonin and type 2 diabetes, in line with the nature of a case–control study. A cohort study, and particularly a Mendelian randomisation study, can be expected to reveal the causal relationship between melatonin and type 2 diabetes (ESM Fig. 3), since both loss-of-function and gain-of-function of melatonin receptor gene MTNR1B have been reported in different populations [17, 21, 48]. Although there is no evidence indicating a causal relationship between gut microbiota and type 2 diabetes by Mendelian randomisation, the metabolites of gut microbiota (e.g. short-chain fatty acids) have been demonstrated to be a causal factor [49], suggesting that the causal relationship between Trp metabolites and type 2 diabetes could be explored in the future. In addition, sequencing of 16S rRNA of gut microbiota could not identify bacteria at the species level, thus metagenomic sequencing is warranted in the future to reveal the specific bacterial species and their functions.

Future studies investigating the causal relationship between melatonin and type 2 diabetes would validate the findings of the current analysis, and exploring the underlying mechanism involving the gut microbiota through metagenomic sequencing and analysis of targeted Trp metabolites may extend the therapeutic targets for type 2 diabetes to specific microbial species.

Conclusion

This study significantly extends our understanding of the relationship between melatonin and type 2 diabetes into the Chinese population and the underlying mechanism involving gut microbiota. Overall, our results show that higher levels of serum melatonin are associated with lower risk of type 2 diabetes. The underlying mechanism may involve alteration of gut microbiota, in which Bifidobacterium and Coprococcus-mediated Trp metabolites may serve as part of the potential mechanism. Our findings suggest that melatonin and melatonin-related gut microbiota and metabolites may be potent therapeutic targets for type 2 diabetes. Further studies are needed to valid the causal effect of melatonin in type 2 diabetes.