We present numerical simulations of axisymmetric , magnetically driven relativistic jets . Our special-relativistic , ideal-MHD numerical scheme is specifically designed to optimize accuracy and resolution and to minimize numerical dissipation . In addition , we implement a grid-extension method that reduces the computation time by up to three orders of magnitude and makes it possible to follow the flow up to six decades in spatial scale . To eliminate the dissipative effects induced by a free boundary with an ambient medium we assume that the flow is confined by a rigid wall of a prescribed shape , which we take to be z \propto r ^ { a } ( in cylindrical coordinates , with a ranging from 1 to 3 ) . We also prescribe , through the rotation profile at the inlet boundary , the injected poloidal current distribution : we explore cases where the return current flows either within the volume of the jet or on the outer boundary . The outflows are initially cold , sub-Alfvénic and Poynting flux-dominated , with a total–to–rest-mass energy flux ratio \mu \sim 15 . We find that in all cases they converge to a steady state characterized by a spatially extended acceleration region . The acceleration process is very efficient : on the outermost scale of the simulation as much as \sim 77 \% of the Poynting flux has been converted into kinetic energy flux , and the terminal Lorentz factor approaches its maximum possible value ( \Gamma _ { \infty } \simeq \mu ) . We also find a high collimation efficiency : all our simulated jets ( including the limiting case of an unconfined flow ) develop a cylindrical core . We argue that this could be the rule for current-carrying outflows that start with a low initial Lorentz factor ( \Gamma _ { 0 } \sim 1 ) . Our conclusions on the high acceleration and collimation efficiencies are not sensitive to the particular shape of the confining boundary or to the details of the injected current distribution , and they are qualitatively consistent with the semi-analytic self-similar solutions derived by Vlahakis & Königl . We apply our results to the interpretation of relativistic jets in AGNs : we argue that they naturally account for the spatially extended accelerations inferred in these sources ( \Gamma _ { \infty } \ga 10 attained on radial scales R \ga 10 ^ { 17 } { cm } ) and are consistent with the transition to the matter-dominated regime occurring already at R \ga 10 ^ { 16 } { cm } .