To understand the stability of deep underground engineering rocks at high temperatures, it is necessary to conduct comprehensive tests on the mechanical properties of the rocks. In this study, a series of true triaxial tests (TTT) were conducted on sandstones using a self-developed true triaxial testing system combined with XRD, FE-SEM and CT analyses. The study systematically examined the microstructural characteristics, physical phase behavior, deformation properties and internal fracture development of the sandstone before and after heat treatment. The results of the study show that sandstone has temperature-dependent true triaxial mechanical properties after heat treatment. The stress-strain characteristic curves of the post-peak portion from room temperature to 800 °C show a significant stress-reducing segment, indicating the presence of brittle behavior. In addition, when the temperature exceeds 1000 °C, the sandstone exhibits brittle-ductile change characteristics, with a peak stress threshold observed at 800 °C. Notably, the peak stresses corresponding to 800 °C increased by 84.5 %, 63.1 %, 47 %, and 49.8 %, respectively, compared with the room temperature intermediate principal stresses(IPS) ranging from 20 MPa to 50 MPa, respectively. Importantly, the linear Mogi-Coulomb criterion remains valid for the peak strength of the high-temperature sandstone, while the internal fracture damage pattern of the specimens shows an inverted "Y" or inverted "W" configuration. The internal fracture network of rock samples above 800 °C is more complex. Intergranular crack is the main form of microcracking. This experimental study on the mechanical properties of sandstone under the combined effects of high temperature and real triaxial stresses provides valuable guidance for the selection of sandstone parameters and safety evaluation of coal underground gasification roofs.