Thermospheric winds usually flow from noon to the midnight inside the polar cap and spill further equatorward around midnight, due to the combined effects of solar radiation‐driven pressure gradient and ion drag. Recent observations from the Scanning Doppler Imager at Poker Flat indicated a distinct feature that the cross‐polar jet stalls over short horizontal distances around the magnetic midnight. However, the mechanisms responsible for the occurrence of stalling have not been well understood. In this study, we investigated the physical mechanisms of the stalling of the cross‐polar jet based on the Thermosphere Ionosphere Electrodynamics General Circulation Model simulations. The model reproduced the general stalling features at midnight over a short horizontal distance. The occurrence of stalling is mainly associated with Joule heating, which enhances the neutral temperature and then turns winds poleward by the pressure gradient force, and ion‐neutral coupling, which drags neutral winds westward in the pre magnetic local time midnight sector and contributes to the poleward turning of the meridional winds by the poleward Coriolis force. Meanwhile, the stalling region has a large latitudinal range and depends on the interplanetary magnetic field (IMF). Under southward IMF Bz, thermospheric winds are likely to stall at lower latitudes associated with strong ionospheric convection. The stalling of the cross‐polar jet in the midnight thermospheric winds has UT/longitude dependence, which could be associated with the orientation of the alignment of geomagnetic and geographic poles with respect to ionospheric convection.