An extensive data set describing effects of the herbicide linuron on macrophyte-dominated microcosms was analysed with a food web model to assess effects on ecosystem functioning. We showed that sensitive phytoplankton and periphyton groups in the diets of heterotrophs were gradually replaced by more tolerant phytoplankton species as linuron concentrations increased. This diet shift - showing redundancy among phytoplankton species - allowed heterotrophs to maintain their functions in the contaminated microcosms. On an ecosystem level, total gross primary production was up to hundred times lower in the treated microcosms but the uptake of dissolved organic carbon by bacteria and mixotrophs was less sensitive. Food web efficiency was not consistently lower in the treated microcosms. We conclude that linuron predominantly affected the macrophytes but did not alter the overall functioning of the surrounding planktonic food web. Therefore, a risk assessment that protects macrophyte growth also protects the functioning of macrophyte-dominated microcosms.