Metabolic dysfunction-associated steatotic liver disease (MASLD) is a clinicopathological syndrome characterized by abnormal accumulation of fat within hepatocytes, and there is currently no standardized clinical treatment available. Consequently, there is an urgent need to discover new pharmacological interventions and to investigate novel therapeutic targets for MASLD. Melatonin, known for its multifaceted biological functions, has shown therapeutic potential for the treatment of MASLD. However, the underlying mechanisms remain unclear, particularly since the direct targets of melatonin have not yet been discovered. In our study, we found that melatonin significantly improved various indicators in a mouse MASLD model and protected palmitic acid induced mouse hepatocytes from lipid accumulation. We successfully identified and validated the mitochondrial trifunctional enzyme α-subunit HADHA as a binding target for melatonin using the cellular thermal shift assay (CETSA). This interaction enhances the expression of PGC-1α, which subsequently promotes mitochondrial biogenesis and accelerates lipid metabolism. In addition, melatonin reduces lipid accumulation and ameliorates MASLD through its regulatory effect on key proteins involved in fatty acid metabolism, including Acyl coenzyme A oxidase 1, CD36, and Fatty acid synthase. Importantly, these beneficial effects are diminished when HADHA is knocked down. In conclusion, our study suggests that melatonin ameliorates MASLD through HADHA-mediated regulation of mitochondrial biogenesis and lipid oxidation, highlighting its potential as a promising therapeutic agent for MASLD. These results lay a theoretical foundation and offer novel insights and strategies into the role of melatonin in the treatment of MASLD.