Sandstone is a common type of rock found in coal measure reservoirs, and its pore and fracture distributions are key factors influencing the comining of coal and gas. To improve the structure of coal measure reservoirs and enhance interlayer compatibility, a method for high-and low-temperature cyclic impact on sandstone was developed in this study, and the effects of high-temperature (+200 °C) and low-temperature (−196 °C) cyclic impacts (number of cycles: 0, 1, 5, 10, and 15) on the pore and fracture distribution characteristics of sandstone were investigated. Ultrasonic testing, low-temperature nitrogen adsorption tests, micro-CT scanning, uniaxial compression tests, and acoustic emission (AE) tests were employed to analyze and characterize the distribution patterns of the pores and fractures in sandstone under different impact conditions. With the increase in the number of high-and low-temperature cyclic impacts, the peak pore and fracture diameters and porosities of the sandstone samples were found to increase logarithmically, whereas the P-wave velocity, uniaxial compressive strength, and AE b value decreased logarithmically. After the fifth high-and low-temperature cyclic impact, the relative decay rate of the P-wave velocity and the increase in the porosity of the sandstone samples reached maximum, which were 20.86% and 20.98%, respectively. The application of highand low-temperature cyclic impact could promote the development of pore fractures and the emergence of secondary fractures in sandstone, forming a pore network. The cyclic thermal impact helped improve the pore fracture distribution and increase the number of transport channels for coal gas molecules, thus enhancing the permeability and interlayer compatibility of sandstone and creating the necessary conditions for the colayering and comining of coal and gas.