We investigate the determinants of the efficiency of firms with a focus on the role of corruption. We construct a simple theoretical model where corruption increases the factor requirements of firms because it diverts managerial effort away from factor coordination. We then exploit a unique dataset comprising firm-level information on 80 electricity distribution firms from 13 Latin American countries for the years 1994 to 2001. As predicted by the model, we find that more corruption in the country is strongly associated with more inefficient firms, in the sense that they employ more inputs to produce a given level of output. The economic magnitude of the effects is large. The results hold both in models with country and firm fixed effects. The results survive several robustness checks, including different measures of output and efficiency, and instrumenting for corruption. Other elements associated with inefficiency are public ownership, inflation, and lack of law and order, but corruption appears to play a separate and more robust role.