Although well-intentioned diversity, equity, and inclusion (DEI) initiatives aim to increase minority representation in elite groups, they can sometimes backfire by causing candidates to question whether they were selected for merit. Prior work in social psychology suggests that this effect is driven mainly by stereotype threat. Here, we propose a novel cognitive framework: DEI initiatives backfire due to causal inference. Specifically, when candidates hear that they were selected based on a DEI initiative and/or enter a group where they are a minority, they may hypothesize that their selection was based more on their identity and less on their merit. Across two pre-registered experiments manipulating selection messages (DEI vs. merit) and statistical gender representation (represented or under-represented in the selected group), we find evidence in favor of our hypothesis. DEI messages and under-representation independently caused successful candidates to attribute their selection more to their identity and less to their merit but did not directly impact perceptions of competence. A third pre-registered experiment revealed that women selectively rated themselves as less competent in DEI contexts when selection tasks were more difficult. Taken together, this work shows that people make different causal hypotheses about their selection into elite groups based on DEI messages and group composition in conjunction with selection task difficulty and their social identity. Importantly, this work paves the way for designing DEI-based initiatives that license more helpful causal inferences about success to ensure that minority candidates thrive in their positions.