Summary In this article, we propose a family of semiparametric transformation models with time-varying coefficients for recurrent event data in the presence of a terminal event such as death. The new model offers great flexibility in formulating the effects of covariates on the mean functions of the recurrent events among survivors at a given time. For the inference on the proposed models, a class of estimating equations is developed and asymptotic properties of the resulting estimators are established. In addition, a lack-of-fit test is provided for assessing the adequacy of the model, and some tests are presented for investigating whether or not covariate effects vary with time. The finite-sample behavior of the proposed methods is examined through Monte Carlo simulation studies, and an application to a bladder cancer study is also illustrated.