Extracting the unique information on ultradense nuclear matter from the gravitational waves emitted by merging neutron-star binaries requires robust theoretical models of the signal. We develop a novel effective-one-body waveform model that includes, for the first time, dynamic (instead of only adiabatic) tides of the neutron star as well as the merger signal for neutron-star-black-hole binaries. We demonstrate the importance of the dynamic tides by comparing our model against new numerical-relativity simulations of nonspinning neutron-star-black-hole binaries spanning more than 24 gravitational-wave cycles, and to other existing numerical simulations for double neutron-star systems. Furthermore, we derive an effective description that makes explicit the dependence of matter effects on two key parameters: tidal deformability and fundamental oscillation frequency.