Background One of the most common hepatic disorders is nonalcoholic fatty-liver disease. The best model used for nonalcoholic fatty-liver disease is the monosodium glutamate (MSG)-induced obesity. MSG is a common flavor enhancer used in different food products. Vitamin-D deficiency increased risks of obesity and nonalcoholic fatty-liver disease. However, much is still unknown about the link between vitamin D and nonalcoholic fatty-liver disease in obesity. Aim The aim was to investigate the effect of vitamin D on MSG-induced obesity and nonalcoholic fatty-liver disease in rats. Materials and methods Forty adult male albino rats were divided into four equal groups: control group, vitamin-D-treated group, MSG-treated group, MSG, and vitamin-D-treated group, at the end of the experimental period, blood samples were taken. Also, livers were dissected for histopathology. Results Vitamin D+MSG significantly decreased the body weight, serum levels of glucose, insulin and homeostasis model assessment-estimated insulin resistance, triglycerides, tumor necrosis factor-alpha, aspartate aminotransferase, alanine aminotransferase, and the liver malondialdehyde, while increased the liver glutathione levels and improved the liver histological findings compared with MSG group. Conclusion Vitamin D has a hepatoprotective effect on the MSG-induced obesity and nonalcoholic fatty-liver disease.