ABSTRACT We present an emulator that accurately predicts the power spectrum of galaxies in redshift space as a function of cosmological parameters. Our emulator is based on a second-order Lagrangian bias expansion that is displaced to Eulerian space using cosmological N-body simulations. Redshift space distortions are then imprinted using the non-linear velocity field of simulated particles and haloes. We build the emulator using a forward neural network trained with the simulations of the BACCO project, which covers an eight-dimensional parameter space including massive neutrinos and dynamical dark energy. We show that our emulator provides unbiased cosmological constraints from the monopole, quadrupole, and hexadecapole of a mock galaxy catalogue that mimics the BOSS-CMASS sample down to non-linear scales ($k\sim 0.6{h\, {\rm Mpc}^{-1}}$). This work opens up the possibility of robustly extracting cosmological information from small scales using observations of the large-scale structure of the universe.