Purpose Surgical patients are at high risk for developing infectious complications and postoperative delirium. Prolonged infections and delirium result in worse outcome. Granulocyte-macrophage colony-stimulating factor (GM- CSF) and influenza vaccination are known to increase HLA-DR on monocytes and improve immune reactivity. This study aimed to investigate whether GM-CSF or vaccination reverses monocyte deactivation. Secondary aims were whether it decreases infection and delirium days after esophageal or pancreatic resection over time. Methods In this prospective, randomized, placebo-controlled, double-blind, double dummy trial setting on an interdisciplinary ICU of a university hospital 61 patients with immunosuppression (monocytic HLA-DR [mHLA-DR] <10,000 monoclonal antibodies [mAb] per cell) on the first day after esophageal or pancreatic resection were treated with either GM-CSF (250 μg/m2/d), influenza vaccination (Mutagrip 0.5 ml/d) or placebo for a maximum of 3 consecutive days if mHLA-DR remained below 10,000 mAb per cell. HLA-DR on monocytes was measured daily until day 5 after surgery. Infections and delirium were followed up for 9 days after surgery. Primary outcome was HLA-DR on monocytes, and secondary outcomes were duration of infection and delirium. Results mHLA-DR was significantly increased compared to placebo (p < 0.001) and influenza vaccination (p < 0.001) on the second postoperative day. Compared with placebo, GM-CSF-treated patients revealed shorter duration of infection (p < 0.001); the duration of delirium was increased after vaccination (p = 0.003). Conclusion Treatment with GM-CSF in patients with postoperative immune suppression was safe and effective in restoring monocytic immune competence. Furthermore, therapy with GM-CSF reduced duration of infection in immune compromised patients. However, influenza vaccination increased duration of delirium after major surgery.