I investigate numerically the flow of an electrically conducting fluid in a differentially rotating spherical shell, in the presence of an imposed magnetic field. For a very weak field the flow is seen to consist of an Ekman layer on the inner and outer spherical boundaries, and a Stewartson layer on the cylinder circumscribing the inner sphere and parallel to the axis of rotation, in agreement with the classical non-magnetic analysis. Bs the field strength is increased, the non-magnetic Ekman layers merge smoothly into magnetic Ekman-Hartmann layers, and the Stewartson layer is suppressed. In the fully magnetic regime the interior flow consists essentially of a solid-body rotation, with the precise rate determined by a torque balance between the inner and outer Ekman-Hartmann boundary layers.