Thermal load causes the structural deformation of the spaceborne active phased array antenna (APAA), which could degrade electromagnetic performance of antenna. The phase com-pensation method and the amplitude-phase compensation method based on the least square method are applied to compensate the electrical performance of the deformed antenna under obtaining the excitation adjustment of antenna elements. Taking the $24 \times 32$ element microstrip array antennas designed in this paper as an example, the compensation effects of the two methods on different observation areas of the antenna are analyzed, which provides a theoretical direction for ensuring the electrical performance of spaceborne APAAs.