T his paper analyzes dynamic efficiency in ports. Using parametric techniques we estimate a stochastic cost frontier to measure overall long-run cost efficiency and an input-oriented directional distance to measure dynamic technical efficiency for a set of 26 Spanish port authorities observed over the period 1993-2012. Technical inefficiency is conceived as the ability of ports to simultaneously expand gross investment and contract variable inputs while maintaining output constant. Ports in this framework are assumed to invest with a view to minimizing the present value of future production costs. Our results show that ports could achieve long-run cost savings of over 38%, two-thirds of which could be achieved by reducing input use and the remainder to changing the input-mix used.