Knowledge creation increasingly requires experts from diverse domains to collaborate in teams, yet the effect of expertise diversity on team knowledge creation is inconclusive. We focus on task uncertainty and informal leadership hierarchies – the disparity in team members’ engagement in leadership activities (task- and relationship-oriented) – to answer the questions when and why expertise diversity may hinder team knowledge creation. We develop a model in which informal leadership hierarchy mediates the conditional indirect effect of the team’s expertise diversity on its knowledge creation under different levels of task uncertainty. We test this moderated mediation model using multi-source data from self-managing project teams comprising collaborators from a pharmaceutical company and its research partners. We find that when task uncertainty is low, the indirect effect of expertise diversity on team knowledge creation is positive, whereas when task