This study identifies the potential role in heat-stress mitigation of phytohormones and other secondary metabolites produced by the endophytic fungus Paecilomyces formosus LWL1 in japonica rice cultivar Dongjin. The japonica rice was grown in controlled chamber conditions with and without P. formosus LWL1 under no stress (NS) and prolonged heat stress (HS) conditions. Endophytic association under NS and HS conditions significantly improved plant growth attributes, such as plant height, fresh weight, dry weight, and chlorophyll content. Furthermore, P. formosus LWL1 protected the rice plants from HS compared with controls, indicated by the lower endogenous level of stress-signaling compounds such as abscisic acid (25.71%) and jasmonic acid (34.57%) and the increase in total protein content (18.76%-33.22%). Such fungal endophytes may be helpful for sustainable crop production under high environmental temperatures.