The large diversity of farms and farming systems in sub-Saharan Africa calls for agricultural improvement options that are adapted to the context in which smallholder farmers operate. The socio-ecological niche concept incorporates the agro-ecological, socio-cultural, economic and institutional dimensions and the multiple levels of this context in order to identify which options fit best. In this paper, we illustrate how farming systems analysis, following the DEED cycle of Describe, Explain, Explore and Design, and embedding co-learning amongst researchers, farmers and other stakeholders, helps to operationalize the socio-ecological niche concept. Examples illustrate how farm typologies, detailed farm characterization and on-farm experimental work, in combination with modelling and participatory approaches inform the matching of options to the context at regional, village, farm and field level. Recommendation domains at these gradually finer levels form the basis for gradually more detailed baskets of options from which farmers and other stakeholders may choose, test and adjust to their specific needs. Tailored options identified through the DEED cycle proof to be more relevant, feasible and performant as compared to blanket recommendations in terms of both researcher and farmer-identified criteria. As part of DEED, on-farm experiments are particularly useful in revealing constraints and risks faced by farmers. We show that targeting options to the niches in which they perform best, helps to reduce this risk. Whereas the conclusions of our work about the potential for improving smallholders’ livelihoods are often sobering, farming systems analysis allows substantiating the limitations of technological options, thus highlighting the need for enabling policies and institutions that may improve the larger-scale context and increase the uptake potential of options.