The effect of environment on the relationship between grain carbon isotope discrimination (D) and yield was studied for durum wheat (Triticum turgidum L. var. durum) in Mediterranean conditions. Twenty-five genotypes were grown under contrasting water regimes in two regions of Spain during three years. The first objective was to determine the environmental factors responsible for the strong relationship between D and yield across trials. The environmental factors tested were: total water input (Wi), mean temperature, accumulated reference evapotranspiration (ET0) and the ratio Wi/ET0 during different periods of the crop cycle. Wi during grain filling was the best variable correlated with grain D and yield across all the trials, as well as across the subset of trials in NE Spain, whereas in SE-Spain (the most drought-prone of the two regions), it was Wi from sowing to heading. The second objective was to study the effect of environment on the relationship between D and yield across genotypes. No significant (P < 0.05) relationship was found for trials with a mean yield of around 2000 kg ha-1, but the strength of the relationship increased sharply to attain significance (P < 0.05) within trials of 2500 kg ha-1, and above this yield it remained relatively steady and positive (r around 0.5).