Accelerators magnets must have minimal magnetic field imperfections for reducing particle-beam instabilities. In the case of coils made of high-temperature superconducting (HTS) tapes, the field imperfections from persistent currents need to be carefully evaluated. In this paper we study the use of superconducting screens based on HTS tapes for reducing the magnetic field imperfections in accelerator magnets. The screens exploit the magnetization by persistent currents to cancel out the magnetic field error. The screens are aligned with the main field components, such that only the undesired field components are compensated. The screens are passive, self-regulating, and do not require any external source of energy. Measurements in liquid nitrogen at 77 K show for dipole-field configurations a significant reduction of the magnetic-field error up to a factor of four. The residual error is explained via numerical simulations, accounting for the geometrical imperfections in the HTS screens, thus achieving satisfactory agreement with experimental results. Simulations show that if screens are increased in width and thickness, and operated at 4.5 K, field errors may be eliminated almost entirely for the typical excitation cycles of accelerator magnets.