Abstract Lanthanide elements play important roles as an opacity source in the ejected material from neutron star mergers. Accurate and complete atomic data are necessary to evaluate the opacities and to analyze the observed data. In this paper, we perform extended, ab initio atomic calculations from Pr ii (Z = 59) to Gd ii (Z = 64). By using multiconfiguration Dirac–Hartree–Fock and relativistic configuration-interaction methods, implemented in the general-purpose relativistic atomic structure package (GRASP2K), we calculate the energy levels and transition data of electric dipole transitions. These computations are based on strategies (with small variations) of Nd ii published by Gaigalas et al. Accuracy of data is evaluated by comparing computed energy levels with the National Institute of Standards and Technology (NIST) database or other works. For the energy levels, we obtain the average relative accuracy of 8%, 12%, 6%, 8%, and 7% for Pr ii, Pm ii, Sm ii, Eu ii, and Gd ii ions, respectively, as compared with the NIST data. Accuracy of energy transfer to the wavelength is 3%, 14%, and 11% for Pr ii, Eu ii, and Gd ii. Our computed E1 type transition probabilities are in good agreement with experimental values presented by other authors especially for strong transitions.