In this study, an approximate analytical solution of the magnetohydrodynamic natural convection flow and heat generation fluid driven by a continuously moving permeable surface immersed in a fluid-saturated porous medium is obtained using the homotopy perturbation method. The homotopy perturbation method produces analytical expressions for the solution of nonlinear differential equations. The obtained analytic solution is in the form of an infinite power series. In this work, the analytical solution is obtained by a special version of the homotopy perturbation method called the single-parameter homotopy perturbation method. In this method, only two terms of the homotopy perturbation method solution are used. The results reveal that the proposed method is very effective and simple, and it can be applied to other nonlinear problems. Also, it is shown that this method coincides with the perturbation method for the studied problem.