This study focuses on the analysis of the first integrals, the integrating factors and the solutions for some classes of nonlinear dynamical systems represented by a mass–spring–damper model. The study consists of the applications of local–nonlocal transformations and the extended Prelle–Singer approach by considering the relation with Lie symmetry groups and \(\lambda \)-symmetry. In addition, the mathematical relations between these methods are presented, and time-dependent and time-independent first integrals and the corresponding exact solutions of nonlinear dynamical systems such as general Morse oscillator equation, the path equation, the harmonic oscillator equation and the displaced harmonic oscillator equation as special cases of Lienard-type equations are investigated. Furthermore, the general forms of Lienard-type equations including general nonlinear damping and nonlinear spring functions are studied.