In the present study, variational iteration and Adomian decomposition methods are applied for solving a class of fractional optimal control problems (FOCPs). Also a comparative study between these two methods is presented. The fractional derivative in these problems is in the Caputo sense. To solve the problem, first the necessary optimality conditions of FOCP are achieved for a linear tracking fractional optimal control problem and then these two methods are used to solve the resulting fractional differential equations. It is shown that the modified Adomian decomposition method and variational iteration method use the same iterative formula for solving linear and nonlinear FOCPs. The convergence of the modified Adomian decomposition method is analytically studied and to illustrate the validity and applicability of the methods, some examples are provided.