This paper studies linear and nonlinear optical properties of the GaAs spherical quantum dot (QD) with impenetrable walls, containing on-center hydrogen impurity, under the presence of the static magnetic field. Transition energy and electric dipole transition matrix element between the impurity electron ground and the first excited state with \(m = 0\) have been computed using the Lagrange mesh method within the effective mass approximation. The linear and the third-order nonlinear optical absorption coefficients (ACs) are obtained using the iterative procedure in the framework of the density matrix approach, and their behavior with respect to the incident photon energy is discussed. In addition, the dependence of these coefficients on the QD radius, magnetic field strength, intensity of the applied laser field and relaxation time is studied. It has been found that for large values of relaxation time, the nonlinear AC prevails over the linear one and the total AC becomes negative.