In this article we investigate heat and mass transfer effects in the magnetohydrodynamic (MHD) flow of an Oldroyd-B fluid in a porous space. In addition, thermal radiation, Joule heating and thermophoresis are considered. The relevant equations are first developed and then computed by the homotopy analysis method. The local Nusselt and Sherwood numbers are also analyzed. The dimensionless velocity, temperature and concentration fields are displayed and discussed for various emerging parameters of interest.