To assess the efficacy of noninvasive ventilation (NIV) in patients with persistent weaning failure, we conducted a prospective, randomized, controlled trial in 43 mechanically ventilated patients who had failed a weaning trial for 3 consecutive days. This trial was stopped after a planned interim analysis. Patients were randomly extubated, receiving NIV (n = 21), or remained intubated following a conventional-weaning approach consisting of daily weaning attempts (n = 22). Compared with the conventional-weaning group, the noninvasive-ventilation group had shorter periods of invasive ventilation (through tracheal intubation) (9.5 +/- 8.3 vs. 20.1 +/- 13.1 days, p = 0.003) and intensive care unit (ICU) (14.1 +/- 9.2 vs. 25.0 +/- 12.5 days, p = 0.002) and hospital stays (27.8 +/- 14.6 vs. 40.8 +/- 21.4 days, p = 0.026), less need for tracheotomy to withdraw ventilation (1, 5% vs. 13, 59%, p < 0.001), lower incidence of nosocomial pneumonia (5, 24% vs. 13, 59%, p = 0.042) and septic shock (2, 10% vs. 9, 41%, p = 0.045), and increased ICU (19, 90% vs. 13, 59%, p = 0.045) and 90-day survival (p = 0.044). The conventional-weaning approach was an independent risk factor of decreased ICU (odds ratio: 6.6; p = 0.035) and 90-day survival (odds ratio: 3.5; p = 0.018). Earlier extubation with NIV results in shorter mechanical ventilation and length of stay, less need for tracheotomy, lower incidence of complications, and improved survival in these patients.