The COVID-19 pandemic has caused great harm to people around the world. This article explores the relationship between healthy diets and the fatality rate of COVID-19 from the perspective of healthy diets. This article collects data from Kaggle, pre-processes and standardizes it, conducts principal component analysis(PCA), divides it into five different dietary patterns(The contribution rate of these five dietary patterns is 72.917%, which can be interpreted as the principal component), and then constructs a multiple linear regression model. In the construction of this model, this article uses the idea of stepwise regression to remove variables that are not significant, leaving the parameters of the first and second principal components significantly non-zero. The results show that the estimated value of the parameter for the first dietary pattern in linear regression is 0.013, whereas the estimated value of the parameter for the second dietary pattern in linear regression is -0.005. Vegetable oils and vegetable products are negatively correlated with the fatality rate of COVID-19, while starchy root foods and animal products are positively correlated with it. Finally, the conclusion is drawn: In normal meals, it is more important to pay attention to the intake of vegetable foods, and try to ensure that the intake of meat foods should also be accompanied by a large amount of different types of vegetables. In the process of cooking, try to use vegetable oils such as soybean oil, olive oil, etc., which contain a lot of vitamin E and unsaturated fatty acids. For starchy root foods and certain high-protein, high-fat animal products, try to eat less in life. On the premise of ensuring good eating habits, it will have a good protective effect on COVID-19.