Invasive ants shape assemblages and interactions of native species, but their effect on fundamental ecological processes is poorly understood. In East Africa, the big-headed ant (Pheidole megacephala) invades monodominant stands of the ant-tree Acacia drepanolobium, displacing native ant defenders and rendering trees vulnerable to elephants (Loxodonta africana) and other browsing ungulates. We quantified A drepanolobium photosynthesis and transpiration pre- and post-invasion by P. megacephala. After ca. 5 years, ant invasion resulted in 69% lower whole-tree carbon fixation during the growing season, despite shorter-term (< 1 year) positive effects on photosynthetic rates coinciding with the displacement of energetically costly native ants. By experimentally excluding ants and large herbivores, we demonstrate that reduced carbon fixation resulted largely from browsing on trees by large herbivores in invaded areas. Our results from individual trees likely scale up, highlighting the potential of invasive species to alter carbon fixation and other biogeochemical cycles at ecosystem scales.