Objective: To investigate and analyze the energy metabolism characteristics and the correlation between energy metabolism and the risk of secondary bacterial infection in patients with hepatitis B virus-related chronic liver disease (HBV-CLD). Methods: Data of 183 cases admitted to the Mengchao Hepatobiliary Hospital of Fujian Medical University from November 2017 to November 2020 were retrospectively analyzed. 79 cases of chronic hepatitis B, 51 cases of hepatitis B-related liver cirrhosis, and 53 cases of hepatitis B-related liver failure were collected. Among them patients with liver failure and decompensated liver cirrhosis were defined as severe liver disease group. The Quark RMR indirect calorimetry (COSMED Corporation, Italy) was used to exam the patients' energy metabolism condition, and the incidences of secondary bacterial infection of the patients during hospitalization were recorded. Shapiro-Wilk test and normal QQ plot were used to analyze the normal distribution of continuous variable data, which was consistent with the normal distribution and was described by mean ± standard deviation. In addition, if it did not conform to the normal distribution, the median and interquartile distance were used to describe it. Levene's test was used to test the homogeneity of variance of the data, which was consistent with the normal distribution. The t-test was used to compare the means of the two groups of samples. One-way analysis of variance was used to compare the mean values of the three groups of samples, and then the Tukey's test was used to compare the two groups. If the variance was uneven or did not conform to the normal distribution, the Wilcoxon rank sum test was used to compare the differences between the two groups. Kruskal-Wallis test (H test) was used to compare the differences between the three groups of samples, and then the Dunnett's test (Z test) was used for comparison between the two groups. Categorical variable data were analyzed using chi-square test. Logistic regression analysis was used to screen independent risk factors, and the criteria for variable inclusion (P < 0.05). Results: The respiratory entropy (RQ) and non-protein respiratory entropy (npRQ) of the three groups had statistically significant difference (P < 0.05). Among them, the RQ and npRQ of the chronic hepatitis B group were higher than hepatitis B-related liver cirrhosis group and hepatitis B-related liver failure group. There were statistically significant differences in fat oxidation rate (FAT%) and carbohydrate oxidation rate (CHO%) between the three groups (P < 0.05). Compared with hepatitis B-related liver cirrhosis group and hepatitis B-related liver failure group, chronic hepatitis B group (P < 0.05) had lower FAT% and higher CHO%. There were no statistically significant differences in the measured and predicted resting energy expenditure and protein oxidation rate (PRO%) between the three groups. The incidence of secondary bacterial infection in patients with severe liver disease was 48.39% (45/93). Compared with the non-infected group, the RQ and npRQ values of the infected group were significantly decreased (P < 0.05), while FAT% was significantly increased (P < 0.05). Logistic regression analysis showed that glutamyltransferase, cholesterol, and npRQ were independent risk factors for secondary bacterial infections in patients with severe liver disease. Glutamyltransferase elevation, and cholesterol and npRQ depletion had suggested an increased risk of secondary bacterial infection. Subgroup analysis of patients with hepatitis B-related liver failure also showed that compared with non-infected group, RQ value and npRQ value of secondary bacterial infection group were significantly decreased (P < 0.05), while FAT% was significantly increased (P < 0.05). Conclusion: Patients with hepatitis B virus-related chronic liver disease generally have abnormal energy metabolism. Low RQ, npRQ, CHO% and high FAT% are related to the severity of the disease; while npRQ reduction is related to the risk of secondary bacterial infection in patients with severe liver disease, and thus can be used as a clinical prognostic indicator.