Starting from the shell structure in atoms and the significant correlation within electron pairs, we distinguish the exchange-correlation effects between two electrons of opposite spins occupying the same orbital from the average correlation among many electrons in a crystal. In the periodic potential of the crystal with lattice constant larger than the effective Bohr radius of the valence electrons, these correlated electron pairs can form a metastable energy band above the corresponding single-electron band separated by an energy gap. In order to determine if these metastable electron pairs can be stabilized, we calculate the many-electron exchange-correlation renormalization and the polaron correction to the two-band system with single electrons and electron pairs. We find that the electronphonon interaction is essential to counterbalance the Coulomb repulsion and to stabilize the electron pairs. The interplay of the electron-electron and electron-phonon interactions, manifested in the exchange-correlation energies, polaron effects, and screening, is responsible for the formation of electron pairs (bipolarons) that are located on the Fermi surface of the single-electron band.