To explore whether there is an interaction between melatonin (MT) and calcium (Ca2+) in regulating heat tolerance of plants, we analyzed the response of endogenous MT and Ca2+ to heat stress, and examined the effect of MT and Ca2+ on the reactive oxygen (ROS) accumulation, antioxidant system, and transcripts of heat shock factor (HSF) and heat shock proteins (HSPs) of cucumber seedlings under high temperature stress. Seedlings were foliar sprayed with 100 μmol·L-1 MT, 10 mmol·L-1 CaCl2, 3 mmol·L-1 ethylene glycol tetraacetic acid (EGTA, Ca2+ chelating agent) +100 μmol·L-1 MT, 0.05 mmol·L-1 chlorpromazine (calmodulin antagonist, CPZ) +100 μmol·L-1 MT, 100 μmol·L-1 p-chlorophenylalanine (p-CPA, inhibitor of MT) +10 mmol·L-1 CaCl2 or deionized water (H2O), respectively. The results showed that both endogenous MT and Ca2+ in cucumber seedlings were induced by high temperature stress. The seedlings treated with exogenous MT showed significant increases in the mRNA expression of calmodulin (CaM), calcium-dependent protein kinase (CDPK5), calcineurin B-like protein (CBL3) and CBL interacting protein kinase (CIPK2) compared with the control at normal temperature. The mRNA levels of tryptophane decarboxylase (TDC), 5-hydroxytryptamine-N-acetyltransferase (SNAT) and N-acetyl-5-hydroxytryptamine methyltransferase (ASMT), key genes of MT biosynthesis and endogenous MT content were also induced by Ca2+ in cucumber seedlings. Exogenous MT and CaCl2 alleviated the heat-induced oxidative damage through increasing antioxidant ability, reducing the accumulation of reactive oxygen species (ROS), and upregulating the mRNA abundances of HSF7, HSP70.1 and HSP70.11, as evidenced by mild thermal damage symptoms, lower heat injury index and electrolyte leakage under heat stress. The positive effect of MT-induced antioxidant capacity and mRNA expression of HSPs was removed by adding EGTA and CPZ in stressed seedlings. Similarly, the mitigating role of Ca2+ in the peroxidation damage to high temperature stress was reversed by p-CPA. These results suggested that both MT and Ca2+ could induce heat tolerance of cucumber seedlings, which had crosstalk in the process of heat stress signal transduction.