<Add magnets video here>
(A) If you want to “wind up” a pair of repelling magnets, you have to press them together.
(B) If you want to “wind up” a pair of attracting magnets, you have to pull them apart.
EPE between two like charges is like (A). EPE is higher when the charges are closer. Since EPE is defined to be zero when they are infinitely far apart, EPE is positive elsewhere. The closer, the more positive.
EPE between two unlike charges is like (B). EPE is higher when the charges are further apart. Since EPE is defined to be zero when they are infinitely far apart, EPE is negative elsewhere. The closer, the more negative.