Objective: Melatonin (Mel) and its receptors are promising for glycemic control in patients with type-2 diabetes mellitus (T2DM) and its complications, but there is significant heterogeneity among studies. This study aims to investigate the effects of Mel receptor agonist Neu-P11 on glucose metabolism, immunity and islet function in T2DM rats. Methods: In this study, SD rats were treated with high fat diet and streptozotocin (STZ) to establish T2DM model. Glucose oxidase method was used to measure blood glucose level. Glucose and insulin tolerance tests were used to assess glucose metabolism. HE staining was used to observe the pancreatic tissue injury. The apoptosis of islet β cells was analyzed by TUNEL and insulin staining. ROS levels and immune cell expression were analyzed by flow cytometry. IF was used to analyze the activation of microglia. The IgA, IgG, IgM, TNF-α, IL-10, IL-1β, IFN-γ, C-peptide and Insulin levels were determined by ELISA. The expression of CD11b, CD86, cleaved caspase3, p21, and P16 proteins were analyzed by western blot. Results: The results showed that the blood glucose level increased, insulin resistance occurred, spleen coefficient and ROS levels increased, humoral immunity in peripheral blood decreased, and inflammation increased in the model group compared to the control group. After Mel and Neu-P11 treatment, the blood glucose level decreased significantly, insulin sensitivity improved, spleen coefficient and ROS levels decreased, humoral immunity in peripheral blood enhanced, and inflammation improved in T2DM rats. Brain functional analysis of T2DM rats showed that microglia cells were activated, TNF-α and IL-β levels were increased, and IL-10 levels were decreased. Mel and Neu-P11 treatment reversed these indexes. Functional analysis of islet in T2DM rats showed that islet structure inflammation was impaired, islet β cells were apoptotic, p21 and p16 protein expressions were increased, and blood C-peptide and insulin were decreased. Mel and Neu-P11 treatment restored the function of pancreatic β cells and improved the damage of pancreatic tissue. Conclusion: Melatonin and its receptor Neu-P11 can reduce blood glucose level, enhance humoral and cellular immunity, inhibit microglia activation and inflammation, and repair islets β cell function, improve the characterization of T2DM related diseases. Objective: Melatonin (Mel) and its receptors are promising for glycemic control in patients with type-2 diabetes mellitus (T2DM) and its complications, but there is significant heterogeneity among studies. This study aims to investigate the effects of Mel receptor agonist Neu-P11 on glucose metabolism, immunity and islet function in T2DM rats. Methods: In this study, SD rats were treated with high fat diet and streptozotocin (STZ) to establish T2DM model. Glucose oxidase method was used to measure blood glucose level. Glucose and insulin tolerance tests were used to assess glucose metabolism. HE staining was used to observe the pancreatic tissue injury. The apoptosis of islet β cells was analyzed by TUNEL and insulin staining. ROS levels and immune cell expression were analyzed by flow cytometry. IF was used to analyze the activation of microglia. The IgA, IgG, IgM, TNF-α, IL-10, IL-1β, IFN-γ, C-peptide and Insulin levels were determined by ELISA. The expression of CD11b, CD86, cleaved caspase3, p21, and P16 proteins were analyzed by western blot. Results: The results showed that the blood glucose level increased, insulin resistance occurred, spleen coefficient and ROS levels increased, humoral immunity in peripheral blood decreased, and inflammation increased in the model group compared to the control group. After Mel and Neu-P11 treatment, the blood glucose level decreased significantly, insulin sensitivity improved, spleen coefficient and ROS levels decreased, humoral immunity in peripheral blood enhanced, and inflammation improved in T2DM rats. Brain functional analysis of T2DM rats showed that microglia cells were activated, TNF-α and IL-β levels were increased, and IL-10 levels were decreased. Mel and Neu-P11 treatment reversed these indexes. Functional analysis of islet in T2DM rats showed that islet structure inflammation was impaired, islet β cells were apoptotic, p21 and p16 protein expressions were increased, and blood C-peptide and insulin were decreased. Mel and Neu-P11 treatment restored the function of pancreatic β cells and improved the damage of pancreatic tissue. Conclusion: Melatonin and its receptor Neu-P11 can reduce blood glucose level, enhance humoral and cellular immunity, inhibit microglia activation and inflammation, and repair islets β cell function, improve the characterization of T2DM related diseases.