In the field of fluid dynamics, investigation of fluid flows through porous media and mathematical modeling is very difficult work for solving the various challenging problems in applied sciences. The Lie group theory is important approach for solving the differential equations. In this paper, the system of flow equations containing of the conservation of mass and momentum transport equation joined with constitutive model of the Oldroyd–B which is solved using the Lei- group method by finding the symmetries, so that accurate invariant solution in the analysis of velocity is acquired.