We analyze wage differentials and transitions between the formal and informal sectors in urban Mexico. We use panel data on five quarterly waves from Mexico's Urban Employment Survey. We develop a dynamic random effects panel data model consisting of separate wage equations for the two sectors and a logit part explaining the labour market state with wages included as explanatory variables. The model is estimated using simulated maximum likelihood. The estimates show that wage differentials increase with education level. The probability of formal sector employment strongly increases with the wage differential. For male workers, the choice between formal and informal sector is driven by wage differentials and unobserved heterogeneity, and true state dependence is not important. For women, non-participation is the most common labour market state, and true state dependence plays a much larger role.