Diabetes has a genetic component, but it is not an absolute genetic disease, and the magnitude of the role of genetic factors varies in different types of diabetes. So there are also acquired environmental factors and the causes of the disease are very complex. Type 1 diabetes: The main cause is genetic factors or autoimmune defects, which lead to abnormal function or apoptosis of pancreatic beta cells and insufficient secretion of insulin. In addition, such as viral infection and stimulation by harmful substances may also cause the destruction of beta cells. Genetic factors are most evident in this type of diabetes and there is often a family history. Type 2 diabetes: mainly insulin resistance and acquired factors resulting in defective pancreatic beta cell function, both congenital and acquired factors such as metabolic syndrome and obesity. 3. Gestational diabetes: This type is generally due to basal metabolic problems and changes in hormone levels during pregnancy, resulting in disorders of glucose metabolism, which may either first appear during pregnancy or be triggered by previous high-risk factors. It may be related to infection of glucose metabolism by chorionic gonadotropin (HCG) and estrogen. There is some family history of this type, but it is not absolutely inherited. Also obesity can cause gestational diabetes. 4.Other types: With the progress of technology, some special types of diabetes are also found clinically, with characteristics of both type 1 and type 2, such as autoimmune diabetes, and some diabetes caused by special etiologies such as abnormal insulin-producing secretion, pancreatic beta-cell function, genetic abnormalities, and abnormal intestinal flora, but the specific pathogenesis are under research and are inconclusive. The prognosis of these types of diabetes depends on the primary cause. If the primary cause can be eradicated, its resulting hyperglycemia may also be cured, but if its cause is unknown or incurable, it is generally difficult to eradicate. So, in general, genetic and environmental factors are jointly involved in the development of diabetes. Diabetes has a certain genetic component, but the magnitude of genetic influence is not the same between different types.