The role of hypocapnia in the prognosis of cardiogenic acute pulmonary edema (CAPE) was understudied. Researchers sought to determine whether hypocapnia was a risk factor for NIV failure and hospital mortality in CAPE patients for a study. A retrospective observational study of all CAPE patients treated with NIV. Patients were divided into 3 groups based on their PaCO2 levels (hypocapnia, eucapnic, and hypercapnic). The need for endotracheal intubation and/or death was defined as NIV failure. There were 1,138 patients studied, with 390 (34.3%) having hypocapnia, 186 (16.3%) having normocapnia, and 562 (49.4%) having hypercapnia. NIV failure was more common in hypocapnia patients (60 patients, 15.4%) than in eucapnic (16 patients, 8.6%) and hypercapnic (562 patients, 10.7%), with statistical significance (P=0.027), as was hospital mortality, which was 73 (18.7%), 19 (10.2%), and 83 (14.8%) respectively (P=0.026). The presence of a do-not-intubate order, complications related to NIV, a lower left ventricular ejection fraction, a higher SAPS II and SOFA score, and a higher HACOR score at 1 hour of NIV initiation were all predicted factors for NIV failure. Hypocapnia was associated with NIV failure and increased in-hospital mortality in CAPE patients.