This study aimed to explore the moderating effect of role ambiguity and role conflict on the relationship between work engagement and affective organisational commitment. Using convenience sampling, a final sample of 179 IT‐specialists of services companies in southern Spain was obtained. Moderation analyses were performed using the hierarchical regressions and bootstrapping method (Bias‐Corrected confidence intervals). Results showed that work engagement was positively related to affective commitment while role ambiguity and role conflict were negatively related to it. However, only role conflict moderated the relationship between work engagement and affective commitment. That is, at high levels of role conflict, IT‐specialists perceiving higher levels of work engagement reported lower levels of affective commitment. This study highlights the hindrance effect of role conflict on one of the most important consequences of work engagement: affective commitment with the organisation. An adequate definition of role and positions could help to reduce the levels of role conflict, increasing the emotional bond to the organisation.