By solving the coupled equations of the electromagnetic field and electrostatic potential, we investigate solitary waves in an asymmetric electron–positron plasma and/or electron–positron–ion plasmas with delicate features. It is found that the solutions of the coupled equations can capture multipeak structures of solitary waves in the case of cold plasma, which are left out by using the long-wavelength approximation. By considering the effect of ion motion with respect to non-relativistic and ultra-relativistic temperature plasmas, we find that the ions’ mobility can lead to larger-amplitude solitary waves; especially, this becomes more obvious for a high-temperature plasma. The effects of asymmetric temperature between electrons and positrons and the ion fraction on the solitary waves are also studied and presented. It is shown that the amplitudes of solitary waves decrease with positron temperature in asymmetric temperature electron–positron plasmas and decrease also with ion concentration.