This paper considers the estimation of frontier production functions in panel data models. It proposes a multi-stage method to obtain estimates of (1) the parameters of a flexible input requirement function and (2) technical inefficiency decomposed into time-invariant (firm-specific), time-varying, and the residual components. The proposed method is used to analyse labour-use efficiency of Swedish local social insurance offices on the basis of a large panel of observations during the time period 1974-84. Empirical results show: (1) substantial variations in labour-use efficiency among these offices, with the mean efficiencies declining over time; (2) presence of economies of scale, thereby meaning that most of the offices were of suboptimal size.