Optimise control strategies of infectious diseases, identify factors that favour the circulation of pathogens, and propose risk maps are crucial challenges for global health. Ecological niche modelling, once relying on an adequate framework and environmental descriptors can be a helpful tool for such purposes. Despite the existence of a vaccine, yellow fever (YF) is still a public health issue. Brazil faced massive sylvatic YF outbreaks from the end of 2016 up to mid-2018, but cases in human and non-human primates have been recorded until the beginning of 2020. Here we used both human and monkey confirmed YF cases from two epidemic periods (2016/2017 and 2017/2018) to describe the spatial distribution of the cases and explore how biotic and abiotic factors drive their occurrence. The distribution of YF cases largely overlaps for humans and monkeys, and a contraction of the spatial extent associated with a southward displacement is observed during the second period of the epidemics. More contributive variables to the spatiotemporal heterogeneity of cases were related to biotic factors (mammal richness), abiotic factors (temperature and precipitation), and some human-related variables (population density, human footprint, and human vaccination coverage). Both projections of the most favourable conditions showed similar trends with a contraction of the more at-risk areas. Once extrapolated at a large scale, the Amazon basin remains at lower risk, although surrounding forest regions and notably the NorthWest region, would face a higher risk. Spatial projections of infectious diseases often relied on climatic variables only; here for both models, we instead highlighted the importance of considering local biotic conditions, hosts vulnerability, social and epidemiological factors to run the spatial risk analysis correctly: all YF cases occurring later on, in 2019 and 2020, were observed in the predicted at-risk areas.