Aligning food production with biodiversity conservation is one of the greatest challenges of our time. One framing of this challenge is the land-sharing vs. land-sparing debate. Much empirical research has focused on identifying the relationship between agricultural yields and species populations, and using the relative number of species with particular relationships to inform landscape-level management. We feel this is misguided, as such an approach does not guarantee the existence of every species of conservation concern. Here, we show that constrained optimization methods can be used to identify landscape-level solutions which maximize agricultural yields and populations for any number of species. Our results suggest that the relative number of species with particular yield–density curves is not a good indicator as to how landscapes should be managed. Likewise, choosing between blanket sharing or sparing strategies leads to suboptimal outcomes at the landscape scale in many cases. Our framework makes maximum use of the rich information contained in yield–density curves to move beyond black-and-white choices and toward more nuanced, context-specific solutions to aligning biodiversity conservation and agricultural production. Such optimal landscapes will likely have features of both sharing and sparing strategies.