Preterm birth occurs in 11 of live births globally and accounts for 35 of all newborn deaths. Preterm newborns have immature immune systems, with reduced innate and adaptive immunity; their immune systems may be further compromised by various factors associated with preterm birth. The immune systems of preterm infants have a smaller pool of monocytes and neutrophils, impaired ability of these cells to kill pathogens, and lower production of cytokines which limits T cell activation and reduces the ability to fight bacteria and detect viruses in cells, compared to term infants. Intrauterine inflammation is a major contributor to preterm birth, and causes premature immune activation and cytokine production. This can induce immune tolerance leading to reduced newborn immune function. Intrauterine inflammation is associated with an increased risk of early-onset sepsis and likely has long-term adverse immune consequences. Requisite medical interventions further impact on immune development and function. Antenatal corticosteroid treatment to prevent newborn respiratory disease is routine but may be immunosuppressive, and has been associated with febrile responses, reductions in lymphocyte proliferation and cytokine production, and increased risk of infection. Invasive medical procedures result in an increased risk of late-onset sepsis. Respiratory support can cause chronic inflammatory lung disease associated with increased risk of long-term morbidity. Colonization of the infant by microorganisms at birth is a significant contributor to the establishment of the microbiome. Caesarean section affects infant colonization, potentially contributing to lifelong immune function and well-being. Several factors associated with preterm birth alter immune function. A better understanding of perinatal modification of the preterm immune system will allow for the refinement of care to minimize lifelong adverse immune consequences.