We aimed to investigate the effects of melatonin administered before and during endotoxemia on the lung tissue of rats, cytokine, YKL-40, matrix metalloproteinase (MMP) and inhibitor levels, oxidative stress parameters, and energy balance. Sepsis was induced with lipopolysaccharide (LPS), the cell wall molecule of gram negative bacteria. Rats were divided into four groups, Control, LPS (Escherichia coli O127:B8, 20 mg/kg), melatonin (10 mg/kg), and melatonin+LPS (M+LPS). After injections, lung tissues samples were taken for experimental analyses. YKL-40, thiobarbituric acid reactive substances (TBARS), glutathione reductase (GR), glutathione peroxidase (GSH-Px), superoxide dismutase (SOD) enzymes levels were measured, high-energy components were analyzed; tumor necrosis factor-alpha (TNF-α), MMP-2, YKL-40, MMP-9, myeloperoxidase (MPO), tissue inhibitors of matrix metalloproteinase (TIMP)-1, and interleukin (IL)-10 immunoreactivities were investigated. In LPS group, YKL-40, creatine phosphate (both, p < 0.05), SOD, GR, adenosine mono-phophate (AMP), adenosine tri-phosphate (ATP) (for all, p < 0.01) were significantly decreased, while TBARS and adenosine di-phosphate (ADP) levels were increased (p < 0.01, p < 0.05; respectively) compared to other groups. MMP-2 and -9, TIMP-1, TNF-α, IL-10, and MPO immunoreactivity were investigated in LPS group. On the contrary, in M+LPS group, MMP-9, TIMP-1 immunoreactivities were not found and IL-10 and MMP-2 immunoreactivities were found with little involvement. In M+LPS group, YKL-40, GR, AMP, ATP, creatine phosphate (for all, p < 0.05), and SOD (p < 0.01) levels were significantly increased and TBARS levels were decreased (p < 0.05). In our study, we suggest that melatonin exerts a protective and curative effect by reducing the matrix metalloproteinase levels responsible for tissue damage balance, stimulating the release of antioxidant enzymes, regulating cytokines and energy balance during endotoxemia.