The optimization of the matching relationship between solar energy supply and building energy demand is crucial for enhancing solar energy utilization in buildings. In this study, models of solar photothermal integrated heat pump (PT-ASHP) and solar photovoltaic integrated heat pump (PVASHP) systems were established, with a single air source heat pump (ASHP-only) system as a benchmark, based on their implementation in a six-story residential building located in Wuhan. Energy supply-demand matching analysis was conducted at three different time scales using indicators such as On-site energy fraction and On-site energy matching, to evaluate the influence of climate conditions on the thermal and electrical efficiency of the solar energy system. Furthermore, economic and environmental comparisons were made among PT-ASHP, PV-ASHP, and ASHP-only systems. The results showed that the PV-ASHP system had excellent performance with a coefficient of performance of 3.38 and achieved the lowest annual operating cost. Additionally, both PT-ASHP and PV-ASHP systems reduced annual operating costs by 4936.96 CNY and 6980 CNY respectively compared to the ASHP-only system. The PV-ASHP system also exhibited a higher primary energy saving ratio of 22 %, while the PT-ASHP system reduced electricity purchased from the grid resulting in better carbon emissions reduction up to 38.66 tons.