Postoperative pulmonary complications, alveolar-arteriolar oxygen difference ([A-a]O2-diff), peak expiratory flow (PEF) and forced vital capacity (FVC) were compared in patients using continuous positive airway pressure (CPAP) and positive expiratory pressure (PEP) administered by face mask against those of a control group using a deep-breathing device (Triflo). Forty-three consecutive, randomized patients undergoing elective upper abdominal surgery were included. CPAP, PEP and Triflo were administered for 30 consecutive breaths in every waking hour for three days postoperatively. The (A-a)O2-difference increased equally and significantly in the three groups after surgery, reaching a maximum on the first postoperative day. After this day, however, (A-a)O2-diff decreased in the CPAP and PEP groups, being significantly lower in the PEP group compared to the control group, two days postoperatively (p less than 0.05) and significantly lower in both the PEP and CPAP groups three days postoperatively (p less than 0.001 and p less than 0.05, respectively.) PEF did not differ significantly between the groups before or after surgery, while FVC was significantly higher in the PEP and CPAP groups, compared to control, on the third postoperative day (p less than 0.05). Atelectatic consolidation was observed in six of 15 patients in the control group three days postoperatively, the incidence being significantly lower in both the PEP group (0 of 15, p less than 0.001) and the CPAP group (one of 13, p less than 0.05). We concluded that periodic face mask administration of CPAP and PEP are superior to deep breathing exercises with respect to gas exchange, preservation of lung volumes and development of atelectasis after upper abdominal surgery. We also conclude that the simple and commercially available PEP mask is as effective as the more complicated CPAP system.