Growing demand for food, fuel, and fiber is driving the intensification and expansion of agricultural land through a corresponding displacement of native woodland, savanna, and shrubland. In the wake of this displacement, it is clear that farmland can support biodiversity through preservation of important ecosystem elements at a fine scale. However, how much biodiversity can be sustained and with what tradeoffs for production are open questions. Using a well-studied tropical ecosystem in Costa Rica, we develop an empirically based model for quantifying the "wildlife-friendliness" of farmland for native birds. Some 80% of the 166 mist-netted species depend on fine-scale countryside forest elements (≤60-m-wide clusters of trees, typically of variable length and width) that weave through farmland along hilltops, valleys, rivers, roads, and property borders. Our model predicts with ∼75% accuracy the bird community composition of any part of the landscape. We find conservation value in small (≤20 m wide) clusters of trees and somewhat larger (≤60 m wide) forest remnants to provide substantial support for biodiversity beyond the borders of tropical forest reserves. Within the study area, forest elements on farms nearly double the effective size of the local forest reserve, providing seminatural habitats for bird species typically associated with the forest. Our findings provide a basis for estimating and sustaining biodiversity in farming systems through managing fine-scale ecosystem elements and, more broadly, informing ecosystem service analyses, biodiversity action plans, and regional land use strategies.countryside biogeography | habitat use | Las Cruces | radio telemetry | remote sensing M eeting food demands of the world's people in a sustainable manner will require a near-doubling of food production in the next 40 y while halting the loss of biodiversity and ecosystem services (1-5). The conflict inherent in these goals has produced much debate, yielding two contrasting strategies-each at an extreme of spatial scale (6, 7). At the large scale, a so-called "land sparing" strategy pursues maximal yields through intense industrial farming in places with high potential productivity while setting aside separate reserves for biodiversity. Its opposite is a "wildlifefriendly" approach that integrates agricultural production and conservation on a fine scale on land managed for both.Wildlife-friendly farming balances tradeoffs within a single system (8, 9) with conservation benefits derived from much smaller, fine-scale ecosystem elements, whose sustainable contribution to biodiversity remains little known. These fine-scale ecosystem elements, such as single trees, charral (early secondary growth), live fences, fruit and timber plantations, and remnants of native forest of all sizes, determine the potential for farmland to support biodiversity and provide ecosystem services critical for food production (10-13). Quantifying the importance of finescale ecosystem elements in human-dominated landscapes has proven elusive. I...