In this paper, we propose a novel and efficient numerical technique for solving linear and nonlinear fractional differential equations (FDEs) with the
φ
-Caputo fractional derivative. Our approach is based on a new operational matrix of integration, namely, the
φ
-Haar-wavelet operational matrix of fractional integration. In this paper, we derived an explicit formula for the
φ
-fractional integral of the Haar-wavelet by utilizing the
φ
-fractional integral operator. We also extended our method to nonlinear
φ
-FDEs. The nonlinear problems are first linearized by applying the technique of quasilinearization, and then, the proposed method is applied to get a numerical solution of the linearized problems. The current technique is an effective and simple mathematical tool for solving nonlinear
φ
-FDEs. In the context of error analysis, an exact upper bound of the error for the suggested technique is given, which shows convergence of the proposed method. Finally, some numerical examples that demonstrate the efficiency of our technique are discussed.