The effects of an Oldroyd-B fluid on the peristaltic mechanism are examined under the long wavelength assumption. Analytical expressions for the stream function, the axial velocity, and the pressure rise per wavelength are obtained up to the second order in the dimensionless wave number. The effects of the various parameters of interest on the flow are shown and discussed.