Gas-liquid two-phase flow is widely present in industrial applications, and investigating its heat transfer characteristics is vital to ensure process safety and improve productivity. In this paper, a microwave photonics technique, optical carrier-based microwave interferometry (OCMI), is applied to measure the temperature of horizontal gas-liquid two-phase flow and study its heat transfer characteristics. As a non-invasive measurement method, the OCMI-based sensor is employed to monitor the outer wall temperature, enabling indirect tracking of temperature fluctuations in two-phase flow through the established temperature correlation. The measured temperatures are essentially consistent with the actual values, with a deviation within +/- 4 %. To quantitatively describe the heat exchange capacity of gas-liquid two-phase flow, a new metric called heat transfer ratio (HTR) is proposed. The relationship between HTR and dimensionless quantities (i.e., the Reynolds and Prandtl numbers) is systematically analyzed. The results show that HTR rises with increasing two-phase Reynolds number but decreases with increasing liquid Prandtl number. Several heat transfer correlations are introduced to explore the variation of the two-phase Nusselt number with the liquid Reynolds and Prandtl numbers. Specifically, the Nusselt number is found to increase with the liquid Reynolds number, whereas it decreases with the liquid Prandtl number. Furthermore, a correlation between the proposed HTR and the relevant dimensionless parameters is established. Overall, the application of the OCMI technique provides a novel and effective approach for studying the heat transfer characteristics of two-phase flows, and lays a foundation for further elucidating the underlying heat transfer mechanisms in complex flows.