Research on ecological total-factor energy efficiency (ETFEE) is conducive to energy conservation, emission reduction, and ecological protection. This paper focuses on the measurement and decomposition of the ETFEE in the Beijing-Tianjin-Hebei (BTH) region in China. In order to measure the ETFEE values, the window technology is combined with a nonradial and nonoriented SBM-undesirable model considering undesirable outputs to overcome the defect of insufficient data of research objects and ensure the calculation process to be implemented. The findings show that Beijing and Tianjin are DEA-efficient, while Hebei is not. The technological progress rates of Beijing and Tianjin reach up to 11.92% and 14.96%, while that of Hebei retrogresses by 4.47%. The scale efficiencies of Beijing, Tianjin, and Hebei are 97.75%, 86.60%, and 93.81%, respectively, which means that there are potentials for further optimization in the energy structures. The impulse response results between the energy structure and the ETFEE show that the proportions of coal and petroleum have negative effects on the ETFEE, while that of natural gas has a positive effect. The research results can provide reference for decision makers to formulate regional development plans.