The screening effect of dense quantum plasmas on the ground and singly excited states of two-electron atoms are investigated by employing the explicitly correlated Hylleraas configuration-interaction wave functions in the framework of Ritz variational principle. Exponential cosine screened Coulomb potential is used to model the electron–nucleus and interelectronic interactions in the atomic systems. Energy levels for the ground and 1snl1,3L (n≤5 and l≤4) singly excited states of H−, He, Li+, Be2+, and B3+ are reported for screening parameters varying from zero to the value nearing corresponding critical screening parameter. Convergence of our calculations are estimated by systematically increasing the number of basis functions. A thorough comparison with available theoretical predictions on the ground state energies at various screening parameters is made, while for the excited states a comparison with the well-established energies of unscreened atoms is performed. The variation of ionization energy and the validity of Hund’s rule for two-electron systems in dense quantum plasmas are analyzed.