Soil moisture has a direct influence on biomass production, food security, and ecosystem functioning, thus resources management in water‐limited environments could be improved if feedbacks between water and vegetation were fully understood. This study tries to define the sensitivity of annual pastures under the influence of different vegetation covers to soil water availability during two contrasting growing seasons, dry and wet. For this reason, soil water content was continuously monitored during two complete hydrological years using capacitance sensors, which were gathered in soil moisture stations located in open grasslands and beneath tree canopies. Pasture growth was recorded by measurements of its height and by biomass cuts. The study was conducted on three private farms located in savanna‐like ecosystems of Spain (dehesa) with Mediterranean climate. Results highlighted the importance of the topsoil (first 15 cm) as the main layer for water supply of natural grasses. Soils below canopies registered longer and more intense water deficits than those located in grasslands. This was reflected in biomass growth, given that when growing conditions were dry, pasture yield decreased more than 40% in grasslands and more than 50% below tree canopies. The studied ecosystems occupy millions of hectares in Spain and Portugal and present a canopy cover up to 40%. If dry episodes become more frequent in the present century due to climate change, important surface, especially under trees, could become drier, less productive, and therefore more prone to land degradation.