In this paper, the problem of steady two-dimensional magnetohydrodynamic (MHD) stagnation-point flow and heat transfer of an incompressible viscous fluid over a stretching/shrinking sheet is investigated in the presence of velocity and thermal slips. With the help of similarity transformations, the governing Navier–Stokes and the energy equations are reduced to ordinary differential equations, which are then solved numerically using a shooting technique. Interesting solution behavior is observed for the similarity equations with multiple solution branches for certain parameter domain. Fluid velocity increases due to the increasing value of the velocity slip parameter resulting in a decrease in the temperature field. Temperature at a point increases with increase in the thermal slip parameter. The effects of the slips, stretching/shrinking, and the magnetic parameters on the skin friction or the wall shear stress, heat flux from the surface of the sheet, velocity, and temperature profiles are computed and discussed.