Background: ABO-incompatible heart transplantation increases donor availability in young children and is evolving into standard of care in children younger than 2 years. Previous smaller studies suggest similar outcomes to ABO-compatible heart transplantation, but persisting alterations of the immune system in ABO-incompatible recipients might increase the risk of some infections or benefit the graft owing to reduced HLA reactivity. We aimed to assess long-term outcomes in young children after they received ABO-incompatible or ABO-compatible heart transplantation. Methods: In this multicentre, prospective cohort study, we analysed data from the Pediatric Heart Transplant Society registry to compare children who received ABO-incompatible or ABO-compatible heart transplantation before age 2 years between Jan 1, 1999, and June 30, 2018. Given significantly different clinical demographics between the two groups, we also matched each ABO-incompatible recipient to two ABO-compatible recipients using propensity score matching. We assessed patient and graft survival, coronary allograft vasculopathy, malignancy, acute rejection (any episode resulting in augmentation of immunosuppression), and infections (requiring intravenous antibiotic or antiviral therapy or life-threatening infections treated with oral therapy). Findings: We included 2206 children who received a heart transplant before age 2 years, with 11 332·6 patient-years of cumulative observation time. Children who received an ABO-incompatible transplant (n=364) were younger and a larger proportion had congenital heart disease and ventilator and mechanical circulatory support than the ABO-compatible recipients (n=1842). After matching, only differences in blood group (more O in ABO-incompatible and more AB in ABO-compatible groups) and use of polyclonal induction therapy with anti-thymocyte globulins persisted. The two matched groups had similar post-transplantation graft survival (p=0·74), freedom from coronary allograft vasculopathy (p=0·75), and malignancy (p=0·51). ABO-incompatible recipients showed longer freedom from rejection (p=0·0021) in the overall cohort, but not after matching (p=0·48). Severe infections (p=0·0007), bacterial infections (p=0·0005), and infections with polysaccharide encapsulated bacteria (p=0·0005) that share immunological properties with blood group antigens occurred less frequently after ABO-incompatible heart transplantation. Interpretation: ABO-incompatible heart transplantation for children younger than 2 years is a clinically safe approach, with similar survival and incidences of rejection, coronary allograft vasculopathy, and malignancy to ABO-compatible recipients, despite higher-risk pre-transplant profiles. ABO-incompatible transplantation was associated with less bacterial infection, particularly encapsulated bacteria, suggesting that the acquired immunological changes accompanying ABO tolerance might benefit rather than jeopardise transplanted children. Funding: Pediatric Heart Transplant Society.