Early works1 and recent advances in thin-film lithium niobate (LiNbO3) on insulator have enabled low-loss photonic integrated circuits2,3, modulators with improved half-wave voltage4,5, electro-optic frequency combs6 and on-chip electro-optic devices, with applications ranging from microwave photonics to microwave-to-optical quantum interfaces7. Although recent advances have demonstrated tunable integrated lasers based on LiNbO3 (refs. 8,9), the full potential of this platform to demonstrate frequency-agile, narrow-linewidth integrated lasers has not been achieved. Here we report such a laser with a fast tuning rate based on a hybrid silicon nitride (Si3N4)–LiNbO3 photonic platform and demonstrate its use for coherent laser ranging. Our platform is based on heterogeneous integration of ultralow-loss Si3N4 photonic integrated circuits with thin-film LiNbO3 through direct bonding at the wafer level, in contrast to previously demonstrated chiplet-level integration10, featuring low propagation loss of 8.5 decibels per metre, enabling narrow-linewidth lasing (intrinsic linewidth of 3 kilohertz) by self-injection locking to a laser diode. The hybrid mode of the resonator allows electro-optic laser frequency tuning at a speed of 12 × 1015 hertz per second with high linearity and low hysteresis while retaining the narrow linewidth. Using a hybrid integrated laser, we perform a proof-of-concept coherent optical ranging (FMCW LiDAR) experiment. Endowing Si3N4 photonic integrated circuits with LiNbO3 creates a platform that combines the individual advantages of thin-film LiNbO3 with those of Si3N4, which show precise lithographic control, mature manufacturing and ultralow loss11,12.