A numerical model is developed to study the MHD mixed convective boundary layer viscoelastic fluid flow over a stretching sheet embedded in a porous medium in presence of viscous dissipation and non-uniform heat source have been investigated. The variation of porosity is assumed. The governing partial differential equations are converted into ordinary differential equations by applying suitable similarity transformations. Thenumerical solution of the problem is also obtained by the efficient Runge-Kutta-Fehlberg method with shooting technique. Here two types of different heating processes are considered namely, PST and PHF cases. The effect of various physical parameters such as Prandtl number, Eckert number, magnetic parameter, convection parameter and porous parameter which determine the temperature profiles are shown in several plots.Some important findings reported in this work reveals that the effect of viscous dissipation and non-uniform heat source have significant impact in controlling the rate of heat transfer in the boundary layer region.