Studies are being conducted to develop strategies to reduce the adverse effects of flooding stress in plants, including melatonin and nitric oxide (NO) applications. In the present study, we tried six different application subjects: full irrigation - control (FI), flooding stress (FS), FS + application of 50 µM melatonin, FS + application of 100 µM melatonin, FS + application of 50 µM nitric oxide (NO), and FS + application of 100 µM NO. The flooding subjects were subjected to stress 10 days before harvest, which was continued until harvest. Melatonin and nitric oxide were applied to plant leaves twice, with a 1-week interval, by spraying to cover the whole plant. We found that flooding stress reduced in certain agronomic parameters and exerted a negative effect on leaf relative water content (RWC), chlorophyll a, b, carotenoid, and protein content, actual photosynthetic efficiency (PSII), stomatal conductance (gs), and chlorophyll fluorescence (Fv/Fm). In addition to increasing the reactive oxygen species (ROS) production under stress conditions, Flooding stress significantly increased the content of proline, leaf temperature, and antioxidant enzyme activity. The melatonin and nitric oxide doses contributed to plant development as well as regulated the pigment content, thereby promoting the ROS-scavenging antioxidant defense system. The principal component analysis (PCA) performed to evaluate the data collectively revealed that full irrigation yielded the best results for agronomic and physiological parameters. The PCA results demonstrated that FS + application of 100 µM melatonin, located in the region closest to full irrigation conditions, was the most effective application under flooding stress conditions. Melatonin applications are crucial for sustainable agriculture, thereby reducing the yield and quality losses compared to nitric oxide applications in regions where spinach is cultivated, and there is a risk of floods.